Commit Graph

247 Commits

Author SHA1 Message Date
Girish Ramakrishnan e96d80e2f8 Add option to keep the local tarball around 2015-04-11 22:16:23 -07:00
Girish Ramakrishnan 53a925374b Containers are not semver based 2015-04-10 15:15:53 -07:00
Girish Ramakrishnan f196088aa0 test app version is now 0.1.0 2015-04-10 14:41:29 -07:00
Johannes Zellner fd5fd610a7 We do now rely on girish/redis:0.4 for tests 2015-04-10 11:26:58 +02:00
Girish Ramakrishnan cbf9354537 Preserve NODE_ENV in sudo scripts 2015-03-29 21:10:09 -07:00
Girish Ramakrishnan cd09d6762b Restore app from last known backup 2015-03-26 10:48:43 -07:00
Girish Ramakrishnan 0b55b7025b Create backup of box separately from apps 2015-03-26 05:27:14 -07:00
Girish Ramakrishnan 40f474e5ed Backup app before update 2015-03-25 22:52:06 -07:00
Girish Ramakrishnan 8bcab8d084 Delegate data volume creation to script
This will be used to create a btrfs subvolume for each app later
2015-03-25 19:36:44 -07:00
Girish Ramakrishnan 872be78c68 Bump addon versions 2015-03-25 18:15:28 -07:00
Johannes Zellner c6d8145b1e appicons are now in box/ subfolder 2015-03-25 17:16:31 +01:00
Girish Ramakrishnan be62b76186 create archive of version and not HEAD 2015-03-25 02:02:51 -07:00
Johannes Zellner 2a9376d6c9 Generate webadmin assets on release tarball creation
Fixes #271
2015-03-16 18:40:09 +01:00
Girish Ramakrishnan 890a06c4c5 Move admin related constants to separate file
Part of #199
2015-02-25 13:31:22 -08:00
Girish Ramakrishnan 7f8fb44795 Cleanup migration scripts
Rationale for setupTest: migration scripts are are meant to add one time entries
and schema changes and not for 'updated' values 'updated' values belong in setup
script because migration scrips are only run once
2015-02-25 11:41:05 -08:00
Johannes Zellner 091c341c2b Add comment about s3 header for authenticated user access via signed urls 2015-02-18 20:55:53 +01:00
Johannes Zellner 79a6a85a9b Also fixup appstore.js breakage due to uglifyjs 2015-02-18 17:58:27 +01:00
Johannes Zellner 6b0c3e3029 Upload sourceTarballs now with acces to AuthorizedUsers
Old sourceTarballs are still public!

This finally fixes #175
2015-02-18 15:56:08 +01:00
Girish Ramakrishnan cc7970b441 Test postgresql and mysql addons
Fixes #173
2015-02-15 23:07:51 -08:00
Girish Ramakrishnan e785fb9043 Add --ssl flag to s3cmd (works only in 1.5.2) 2015-02-12 13:24:23 -08:00
Girish Ramakrishnan bfb33726f8 Use separate buckets for dev/staging 2015-02-11 11:42:08 -08:00
Girish Ramakrishnan 79250cd0ec Use s3cmd instead of s3-cli since we can pass keys as arg 2015-02-11 10:54:36 -08:00
Girish Ramakrishnan 840d91d53f Use latest test image 2015-02-05 14:31:15 -08:00
Girish Ramakrishnan 7328cf6290 Check for redis:0.2 2015-02-03 23:33:42 -08:00
Girish Ramakrishnan 2455975a46 bash scripts: merge the set lines 2015-01-23 15:01:10 -08:00
Girish Ramakrishnan a9fa5b37a4 Use sudo -k on Mac 2015-01-22 23:01:49 -08:00
Girish Ramakrishnan 3953b96626 set -u all the scripts 2015-01-22 17:04:37 -08:00
Girish Ramakrishnan 1f04a4f41c Add --revision 2015-01-22 16:24:20 -08:00
Johannes Zellner 7506746892 Remove .sh extension for executable shell scripts 2015-01-23 01:10:56 +01:00
Johannes Zellner 2a06533703 Fix the checkInstall.sh by checking the error 2015-01-23 01:08:02 +01:00
Girish Ramakrishnan 06f83b51ba Only mark constants as readonly
This is just a coding style thing because bash gets all worked up
if we reuse these variable names in functions as local

example:

    func() {
        local VAR="value" # does not work even if this is local since VAR is readonly
        echo "${VAR}"
    }

    readonly VAR="deal"
    func
2015-01-21 15:52:14 -08:00
Girish Ramakrishnan 82d14bd1a5 Use double brackets 2015-01-21 14:33:41 -08:00
Girish Ramakrishnan feb748e9b5 checkInstall.sh - fix coding style 2015-01-21 14:32:45 -08:00
Girish Ramakrishnan d149519fc1 createSourceTarball: fix coding style 2015-01-21 14:29:45 -08:00
Girish Ramakrishnan 409f919d4d Ensure top level directory is readable by others
tar --list --verbose --file=box.tar now shows:
drwxr-xr-x girishra/staff    0 2015-01-17 16:57 ./

Without this change, mktemp was creating directories have no r,x for
others and group. This meant that nginx which was running www-user
was unable to access the website inside box code.
2015-01-17 13:59:58 -08:00
Girish Ramakrishnan 63d315ed32 Move image creation scripts to installer repo 2015-01-12 17:10:44 -08:00
Girish Ramakrishnan a87ad700bd Comment out set -x 2015-01-11 00:58:09 -08:00
Girish Ramakrishnan d561649f08 New release script: publish.sh
It takes arguments --image <image_id> or --code <source_code_url>

image_id is generated using scripts/createDigitalOceanImage.sh
source_code_url is generated using scripts/createSourceTarball.sh
2015-01-11 00:44:28 -08:00
Girish Ramakrishnan f193b889ab install server never dies
The install server is now always started by the init script.
When started up, it determines it's mode based on the exitence
of box srcdir. If it does not exist, it starts an external
listening provision/restore server. Once the appstore, provisions
the box, it switches to update mode.

If the box srcdir does exist, the installer starts out in update mode.
In update mode, the server listens on localhost:2020. In this
mode, the web interface can ask it to update the box.

Fixes #115
2015-01-09 22:25:37 -08:00
Girish Ramakrishnan 8a35644518 Implement tarball based installation
* The base image contains only installer code. Installer code
  can only be changed with a base image change
* The box code is download from s3 instead of git. The s3 tarball
  consists of node dependancies already

Part of #115
2015-01-09 15:25:28 -08:00
Girish Ramakrishnan 259747fcdc Check exit status immediately because of set -e 2015-01-09 13:57:55 -08:00
Girish Ramakrishnan 1c71143dc5 Check if redis and test images are present 2015-01-07 22:31:17 -08:00
Girish Ramakrishnan 27364458a7 Fix typo 2015-01-07 13:45:55 -08:00
Girish Ramakrishnan f42c838c4a Pull in redis image 2015-01-07 13:43:53 -08:00
Johannes Zellner 2db84be8ee Sync image creation defaults with heroku config 2015-01-07 22:10:15 +01:00
Johannes Zellner a5d680fd0d Allow specify regions for cloudron images
This reuses the 'regions' argument to transfer the
new image to the list specified. The first entry is the
region, where the temporary droplet is being created.

eg. --regions="ams3 ny2 sfo1"

The image droplet is created in Amsterdam.

The script currently does not wait for all images to be
fully transferred, yet.
2015-01-07 15:57:47 +01:00
Girish Ramakrishnan 71e1efcd2b barf on error 2015-01-06 11:30:08 -08:00
Girish Ramakrishnan f4cfaeacb9 Use the GNU getopt on Mac
getopts - bash built-in that supports only short form
getopt - separate program and there are two variants - GNU and BSD. The BSD one
  does not support long options.
2015-01-06 11:27:36 -08:00
Girish Ramakrishnan 7d70c52863 createDigitalOceanImage: Add --revision, --size, --region args
Possible region slugs as of today are:
nyc1
ams1
sfo1
nyc2
ams2
sgp1

Possible size slugs are:
512mb
1gb
2gb
4gb
8gb
16gb
32gb
48gb
64gb
2015-01-06 11:02:03 -08:00
Girish Ramakrishnan ae2abd9162 Add postgresql to base image 2015-01-05 21:42:03 -08:00