Skip to content

Instantly share code, notes, and snippets.

@constantm
Last active December 5, 2018 10:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save constantm/764192168f02733fe264 to your computer and use it in GitHub Desktop.
Save constantm/764192168f02733fe264 to your computer and use it in GitHub Desktop.
Straight forward deployment of Ember on Semaphore CI
npm install ember-cli -g
npm install
bower install
ember build
ssh-keyscan host.com >> ~/.ssh/known_hosts
tar -cvf tmp.tar.gz -C dist .
scp -r tmp.tar.gz user@host.com:/var/www/versions/
ssh user@host.com "mkdir -p /var/www/versions/$REVISION && tar -xf /var/www/versions/tmp.tar.gz -C /var/www/versions/$REVISION/ && rm /var/www/versions/tmp.tar.gz && rm /var/www/current && ln -s /var/www/versions/$REVISION/ /var/www/current && ls -tr /var/www/leaply-ember/versions | head -n -3 | xargs rm -rf"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment