From 7800dafce323e880cade3a22f3f0c60bcebe2a6b Mon Sep 17 00:00:00 2001 From: Tankred Hase Date: Mon, 14 Aug 2017 19:30:23 +0800 Subject: [PATCH] Remove .elasticbeanstalk/config.yml and shell script for local deployment --- .elasticbeanstalk/config.yml | 12 ---------- res/aws_release.sh | 43 ------------------------------------ 2 files changed, 55 deletions(-) delete mode 100644 .elasticbeanstalk/config.yml delete mode 100755 res/aws_release.sh diff --git a/.elasticbeanstalk/config.yml b/.elasticbeanstalk/config.yml deleted file mode 100644 index 6ac17fc..0000000 --- a/.elasticbeanstalk/config.yml +++ /dev/null @@ -1,12 +0,0 @@ -branch-defaults: - release/prod: - environment: keyserver-prod - release/test: - environment: keyserver-test -global: - application_name: keyserver - default_ec2_keyname: null - default_platform: Node.js - default_region: eu-west-1 - profile: eb-cli - sc: git diff --git a/res/aws_release.sh b/res/aws_release.sh deleted file mode 100755 index 8d9d109..0000000 --- a/res/aws_release.sh +++ /dev/null @@ -1,43 +0,0 @@ -#!/bin/sh - -# go to root -cd `dirname $0` -cd .. - -if [ "$1" != "prod" ] && [ "$1" != "test" ] ; then - echo 'Usage: ./res/aws_release prod|test' - exit 0 -fi - -# switch branch -git checkout master -git branch -D release/$1 -git checkout -b release/$1 -git merge master --no-edit - -# abort if tests fail -set -e - -# build and test -rm -rf node_modules -npm install -npm test - -# install only production dependencies -rm -rf node_modules/ -npm install --production - -# delete .gitignore files before adding to git for aws deployment -find node_modules/ -name ".gitignore" -exec rm -rf {} \; - -# Add runtime dependencies to git -sed -i "" '/node_modules/d' .gitignore -git add .gitignore node_modules/ -git commit -m "Update release" - -# push to aws -eb deploy keyserver-$1 - -# switch back to master branch -git checkout master -npm install