Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add jwt and terraform setting update #2

Merged
merged 32 commits into from
Dec 14, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add enviroment tar file
  • Loading branch information
lcc3108 committed Dec 12, 2019
commit fa61cb3da067df825b4e273246c2b0db02d63ae9
Binary file removed .env.enc
Binary file not shown.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ node_modules
aws_key.json
google_key.json
.terraform
*.tar
*.log
dist
index.zip
Expand Down
73 changes: 36 additions & 37 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,49 +1,48 @@
language: node_js
node_js:
- '8'
- "8"
cache:
npm: true
yarn: true
directories:
- "$HOME/terraform"
- "$HOME/terraform"
env:
global:
- secure: p/c6ViUEAHhs0nV7xWVZCrfxjFwSVVENcT89HwgaPk0t8KsPbmA13dR8Zz6lJ8qUBMpx+MKm0c98/aG/JFUQrc9D8gbpBpU5wJUlHpO4ZdXww2U13+baDFe3md84t7oFxKzEcAvFo0G/tRFTFyir+jgzGwlwAlB18+iKwc+4Zg9GmFgkp/sO84A/SIIAa9VM7ELNG4Z9B8wtYd+iTQfy20noF6M6QYq9HyhU5oeVLjnrchpjUO4SCXsHuh6uAVbCuFNA9yXxrD3IVEedfB0Grpniwvcjlfj+LvximYccn1Ppw+Q6pQEif2ZgfQySuk/T53ZFnZTpEy2U3uc470rLaaRYLiBOdG3Fad1Lh8SOfXPPrX1pc2BOdg4962XtlD//88FXzWyxk2bg4ID27xFc+huWUJ8dEjzFNFjT74o2dO0BW7u0RtK9JqggI2kwcJn4NkbXUomhO7Le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BzabbpaZ8NCoAO+u94O9lQBtDTU2dIVE3qEi6V1WgqYdu28ThfpVAdBl2OSgcGVIpF2lReQ/u/NimbWGwhCuut9YOQA9gRtJUefylHIgy1OMZroFA8466p+mkdTnH39iORNH5Hx/2pgGCPHk8t/jTfp+Y5XwRppSOARph3hKk/FNf9yAqck/aw30OshX9RWqlDN6v48psc2uyinzm9mNEXCdTYmdcrcvyRPK+fPPOQte3FZVUoabJ3mxzD7d68YQuVdJ8R4DtYYAwQYblLtijUrvfDjuCGvnt4syH9y3gytrcsp+q3pALp4I503pvnMtL0RdTQ1Qvy7Z8K1hEu6UzoQl9dnxNZQMYxtjsxfCuPsEAnHhvgGanimZ1H4jtxfnxXpaUOHwLhDDM7k3tgjyJhSGe2E=
before_install:
- openssl aes-256-cbc -K $encrypted_3e39b73e0d5c_key -iv $encrypted_3e39b73e0d5c_iv
-in google_key.json.enc -out google_key.json -d
- openssl aes-256-cbc -K $encrypted_3e39b73e0d5c_key -iv $encrypted_3e39b73e0d5c_iv
-in .env.enc -out .env -d
- |
if [ ! -d "$HOME/terraform/bin" ]; then
rm -rf "$HOME/terraform"
mkdir -p $HOME/terraform/bin
wget https://releases.hashicorp.com/terraform/0.12.16/terraform_0.12.16_linux_amd64.zip
unzip terraform_0.12.16_linux_amd64.zip -d $HOME/terraform/bin/
fi
- export PATH=$PATH:$HOME/terraform/bin
- openssl aes-256-cbc -K $encrypted_3e39b73e0d5c_key -iv $encrypted_3e39b73e0d5c_iv
-in private.tar.enc -out private.tar -d
- tar xvf private.tar
- |
if [ ! -d "$HOME/terraform/bin" ]; then
rm -rf "$HOME/terraform"
mkdir -p $HOME/terraform/bin
wget https://releases.hashicorp.com/terraform/0.12.16/terraform_0.12.16_linux_amd64.zip
unzip terraform_0.12.16_linux_amd64.zip -d $HOME/terraform/bin/
fi
- export PATH=$PATH:$HOME/terraform/bin
install:
- yarn
- yarn
jobs:
include:
- stage: test
script:
- yarn lint
- yarn type-check
- yarn build
- stage: deploy
env: CLOUD=AWS
script:
- yarn build
before_deploy:
- echo credentials \"app.terraform.io\" { token = \"$TOKEN\" } | cat >> ~/.terraformrc
- cp -r ./node_modules ./dist/
- terraform init
deploy:
- provider: script
script: yarn deploy
skip_cleanup: true
on:
branch: jwt
- stage: test
script:
- yarn lint
- yarn type-check
- yarn build
- stage: deploy
env: CLOUD=AWS
script:
- yarn build
before_deploy:
- echo credentials \"app.terraform.io\" { token = \"$TOKEN\" } | cat >> ~/.terraformrc
- cp -r ./node_modules ./dist/
- terraform init
deploy:
- provider: script
script: yarn deploy
skip_cleanup: true
on:
branch: jwt
Binary file removed google_key.json.enc
Binary file not shown.
Binary file added private.tar.enc
Binary file not shown.