Girish Ramakrishnan
10e0cbcebc
do not set allowHalfOpen (otherwise we have to end socket ourself)
2016-05-23 10:50:04 -07:00
Girish Ramakrishnan
37512c4cac
Wrap the stdin stream to indicate EOF
...
The docker exec protocol supports half-closing to signal that the stdin
is finished. The CLI tool tried to do this by closing it's half of the
socket when the stdin finished. Unfortunately, this does not work because
nginx immediately terminates a half-close :/ Node itself has no problem.
http://mailman.nginx.org/pipermail/nginx/2008-September/007388.html
seems to support the hypothesis. Basically, for HTTP and websockets
there is no notion of half-close.
Websocket protocol itself has no half-close as well:
http://www.lenholgate.com/blog/2011/07/websockets---i-miss-the-tcp-half-close.html
http://doc.akka.io/docs/akka/2.4.5/scala/http/client-side/websocket-support.html
The fix is to implement our own protocol that wrap stdin. We put a length
header for every payload. When we hit EOF, the length is set to 0. The server
sees this 0 length header and closes the exec container socket.
2016-05-22 22:27:49 -07:00
Girish Ramakrishnan
0aaaa866e4
Add a whole bunch of magic for docker.exec to work
2016-05-22 00:27:32 -07:00
Girish Ramakrishnan
53cb7fe687
debug out cmd
2016-05-19 15:54:35 -07:00
Girish Ramakrishnan
da42f2f00c
fix boolean logic
2016-05-19 15:54:35 -07:00
Girish Ramakrishnan
efa3ccaffe
fix crash because of missing error handling
2016-05-18 10:00:32 -07:00
Girish Ramakrishnan
e5d906a065
create fake cert/key for tests to pass
2016-05-13 22:35:13 -07:00
Girish Ramakrishnan
3ccb72f891
tests finally work
2016-05-13 22:05:05 -07:00
Girish Ramakrishnan
aa116ce58c
fix tests
2016-05-13 20:21:09 -07:00
Girish Ramakrishnan
8e077660c4
start_addons is redundant
2016-05-13 17:57:56 -07:00
Girish Ramakrishnan
83a28afc8f
addons are started by box code now
2016-05-09 23:56:02 -07:00
Girish Ramakrishnan
e76c7de259
bump test app version
2016-05-09 23:40:59 -07:00
Johannes Zellner
3af95508f5
eventlog getAllPaged is now getByQueryPaged
2016-05-06 17:27:52 +02:00
Johannes Zellner
4c7dc5056d
Add more query options for eventlog api
2016-05-06 16:49:17 +02:00
Johannes Zellner
e986a67d39
Fixup all the unit tests
2016-05-06 15:16:22 +02:00
Johannes Zellner
c7958f8e1d
Remove unused /api/v1/subdomains/:subdomain
2016-05-06 14:51:02 +02:00
Johannes Zellner
c61ce40362
Add /api/v1/profile/tutorial route tests
2016-05-06 14:06:54 +02:00
Johannes Zellner
f3811e3df9
Remove all unused vars in profile test
2016-05-06 14:03:24 +02:00
Johannes Zellner
0d40b1b80d
Fix the test wording in profile password change tests
2016-05-06 14:02:21 +02:00
Johannes Zellner
8b92c8f7ae
Remove unused checkMails() in profile tests
2016-05-06 13:57:46 +02:00
Johannes Zellner
d41eb81b3d
Add new profile/ route to set the showTutorial field
2016-05-06 13:56:40 +02:00
Girish Ramakrishnan
6bcfd33e10
boot2docker is dead
2016-05-04 15:54:21 -07:00
Girish Ramakrishnan
b4c15b1719
Let the box code initialize the infrastructure
...
This is done because:
1. The box code can install certs for addons (like mail addon) when
required.
2. The box code initialize/teardown addons on demand. This is not planned
currently.
2016-05-04 15:54:21 -07:00
Girish Ramakrishnan
7262eb208f
add route to get the timezone
2016-05-03 12:10:21 -07:00
Girish Ramakrishnan
5617baea50
eventlog tests
2016-05-02 14:54:25 -07:00
Girish Ramakrishnan
ffedbdfa13
various minor fixes to eventlog
2016-05-02 10:01:23 -07:00
Girish Ramakrishnan
b322f6805f
move authType into source
2016-05-01 21:53:44 -07:00
Girish Ramakrishnan
ccc119ddec
add appLocation to user login
2016-05-01 21:47:35 -07:00
Girish Ramakrishnan
994cbaa22a
add event log in model code
2016-05-01 21:38:20 -07:00
Girish Ramakrishnan
d7a34bbf68
remove profile action
2016-05-01 20:14:21 -07:00
Girish Ramakrishnan
1f31fe6f8f
make user.remove and user.update add eventlog
2016-05-01 20:11:11 -07:00
Girish Ramakrishnan
37bdd2672b
make user.create take auditSource
2016-05-01 20:01:34 -07:00
Girish Ramakrishnan
63702f836a
move developer eventlogs to model code
2016-05-01 13:46:33 -07:00
Girish Ramakrishnan
5898428a6c
use req.connection.remoteAddress
2016-05-01 13:29:11 -07:00
Girish Ramakrishnan
f4a6c64956
make cloudron.activate take an auditSource
2016-05-01 13:27:57 -07:00
Girish Ramakrishnan
f9d4d3014d
remove reboot (user cannot initiate anyway)
2016-05-01 13:23:31 -07:00
Girish Ramakrishnan
8254337552
make cloudron.updateToLatest take an auditSource
2016-05-01 13:17:35 -07:00
Girish Ramakrishnan
fec388b648
move backup eventlog to model
2016-05-01 13:17:23 -07:00
Girish Ramakrishnan
7967610f3f
add user login to event log
2016-04-30 23:18:14 -07:00
Girish Ramakrishnan
43051cea3b
add app update event
2016-04-30 20:25:20 -07:00
Girish Ramakrishnan
3d50a251ee
store email in USER_ADD event
2016-04-30 20:25:20 -07:00
Girish Ramakrishnan
d3d9706a70
make response plural
2016-04-30 18:57:43 -07:00
Girish Ramakrishnan
8a3ad6c964
store the activation username
2016-04-30 14:32:35 -07:00
Girish Ramakrishnan
90719cd4d9
do not store entire manifest
2016-04-30 14:28:59 -07:00
Girish Ramakrishnan
157fbc89b8
add eventlog route
2016-04-30 14:08:44 -07:00
Girish Ramakrishnan
71219c6af7
add eventlog hooks
2016-04-30 14:05:19 -07:00
Girish Ramakrishnan
c511019d79
remove jslint hint
2016-04-30 11:53:46 -07:00
Girish Ramakrishnan
d2a3925e04
add altDomain to install route
2016-04-26 14:45:58 -07:00
Girish Ramakrishnan
a1e2cd438e
return altDomain in response
2016-04-25 10:52:12 -07:00
Girish Ramakrishnan
3d5aa9fd23
pass altDomain in configure route
2016-04-25 10:52:12 -07:00