Commit Graph

4383 Commits

Author SHA1 Message Date
Pagan Gazzard
148d067ab9 Add a log entry that we're exiting on a supervisor update. 2015-10-13 13:06:42 -03:00
Petros Angelatos
3e1dd1f922 Log every mixpanel event and remove redundant logs 2015-10-13 13:06:42 -03:00
Petros Angelatos
d00372b5d2 Move mixpanel calls inside corresponding methods 2015-10-13 13:06:42 -03:00
Petros Angelatos
d06b5117f0 Keep method of loading JSON files consistent 2015-10-13 13:06:42 -03:00
Petros Angelatos
7b483e983d Fix bug of using mixpanel module as the mixpanel client 2015-10-13 13:06:42 -03:00
Petros Angelatos
e622491f37 Add mixpanel events to the update process 2015-10-13 13:06:42 -03:00
Petros Angelatos
1501cf3122 Integrate mixpanel 2015-10-13 13:06:42 -03:00
Petros Angelatos
0772638d92 Supply USER environment variable to containers 2015-10-13 13:06:42 -03:00
Petros Angelatos
a5fa371f22 Bind mount /lib/modules to enable module loading from inside the container 2015-10-13 13:06:42 -03:00
Page
4cfcd39524 Enable periodic update checks, and add logic to only switch to the new image if it is different. 2015-10-13 13:06:42 -03:00
Page
0d2d372cb9 Share the docker socket via config. 2015-10-13 13:06:42 -03:00
Page
959da25c9f Add all expected env vars to the new supervisor container. 2015-10-13 13:06:41 -03:00
Page
f78786b065 Rename the images more appropriately. 2015-10-13 13:06:41 -03:00
Page
599f8ae503 Remove trailing commas. 2015-10-13 13:06:41 -03:00
Page
96d1e48edd Use a promise constructor so we can make the code a bit cleaner. 2015-10-13 13:06:41 -03:00
Page
a0f9219cb3 Initial version of self-updates, adds an "/v1/update-supervisor" endpoint that can be posted to in order to trigger a supervisor update, which it then fetches as the resin/rpi-supervisor repo of the registry endpoint. 2015-10-13 13:06:41 -03:00
Petros Angelatos
d47ba654b7 Pass the device uuid as an env var 2015-10-13 13:06:41 -03:00
Petros Angelatos
04ca3b3042 Clarify publish function definition 2015-10-13 13:06:41 -03:00
Petros Angelatos
7e5fe4802f Don't filter out ANSI colours 2015-10-13 13:06:41 -03:00
Petros Angelatos
29f5c9b7e0 Use promise API 2015-10-13 13:06:41 -03:00
Petros Angelatos
604a05a21a Style fixes 2015-10-13 13:06:41 -03:00
Petros Angelatos
94eeaaa510 Resolve variable collision 2015-10-13 13:06:41 -03:00
Petros Angelatos
39261f5d6b Enclose publish queuing vars in their own closure 2015-10-13 13:06:41 -03:00
Petros Angelatos
7c33f28724 Queue publish calls while getting uuid from db 2015-10-13 13:06:41 -03:00
Petros Angelatos
ca736233e7 Move all configuration variables to a separate file 2015-10-13 13:06:39 -03:00
Petros Angelatos
5caace400f Send logs through pubnub 2015-10-13 13:04:25 -03:00
Petros Angelatos
9325b258ae Combine scripts 2015-10-13 13:03:16 -03:00
Petros Angelatos
272daea89c Make supervisor deployable with resin 2015-10-13 13:03:16 -03:00
Page
ff7d6c1f8a Add missing paren. 2015-10-13 13:03:16 -03:00
Page
b3f9f9b1ef Switch to using the Promise constructor rather than deferred, it allows for slightly nicer code. Also add some parens in appropriate places. 2015-10-13 13:03:16 -03:00
Page
4d5c18ec6f Fetch the image using dockerode. 2015-10-13 13:03:16 -03:00
Page
7daebaf85e Fix check if we already have the image. 2015-10-13 13:03:16 -03:00
Page
f47e7fbf2b We have to manually stringify/parse the JSON column for knex - fixes containers restarting every 6 minutes. 2015-10-13 13:03:16 -03:00
Petros Angelatos
e9cbeea11e Docker expects the port to be a string 2015-10-13 13:03:16 -03:00
Petros Angelatos
3c4318893a Remove unused version variable 2015-10-13 13:03:16 -03:00
Petros Angelatos
98870dcd16 Generate random UUID
Generate a random UUID when the device bootstraps instead of
deterministically calculating one from the CPU serial number. This means
that a specific device can be used with many applications and users
without problem.
2015-10-13 13:03:16 -03:00
Petros Angelatos
2b054123fe Remove unused crypto module 2015-10-13 13:03:16 -03:00
Petros Angelatos
60c863eeac Update buildstep version to v0.0.7 2015-10-13 13:03:16 -03:00
Petros Angelatos
387ac995a4 Remove unmatched ) 2015-10-13 13:03:16 -03:00
Page
ab642470ec Make sure the PORT env var is a valid port number before trying to bind it. 2015-10-13 13:03:16 -03:00
Page
9ca8077daa Use the PORT environment variable to choose what port to expose.
Conflicts:
	src/application.coffee
2015-10-13 13:03:16 -03:00
Page
99849ad84c Publish tcp ports 80 and 443 of the container.
Conflicts:
	src/application.coffee

Conflicts:
	src/application.coffee
2015-10-13 13:03:16 -03:00
Page
38481f524d Make sure all apps are removed before adding new/updating existing, this is to make sure any ports they use have been freed in case they're needed by the new/updated apps.
Conflicts:
	src/application.coffee
2015-10-13 13:03:15 -03:00
Page
97d2771826 Change automatic update check to every 5 mins instead of 15. 2015-10-13 13:03:15 -03:00
Vasilis Souleles
502fa105b1 removed unnecessary changes part 2 2015-10-13 13:03:15 -03:00
Vasilis Souleles
34cbb1e699 removed unnecessary changes 2015-10-13 13:03:15 -03:00
Vasilis Souleles
e0aa5e3929 fixed dumb bug 2015-10-13 13:03:15 -03:00
Vasilis Souleles
9a87a8fbf5 fixed tabs over spaces 2015-10-13 13:03:15 -03:00
Vasilis Souleles
1c3e173bd3 added resin-supervisor version as a field of config object. added some notes on posting version using resinAPI 2015-10-13 13:03:15 -03:00
Page
5e620cbf03 Fix typo. 2015-10-13 13:03:15 -03:00