File tree Expand file tree Collapse file tree 2 files changed +12
-8
lines changed
Expand file tree Collapse file tree 2 files changed +12
-8
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,8 @@ name: "CD: facilitator (all)"
33on :
44 push :
55 branches :
6- - ' deploy-facilitator-*'
6+ - ' deploy-facilitator-staging'
7+ - ' deploy-facilitator-prod'
78
89jobs :
910 deploy :
Original file line number Diff line number Diff line change @@ -25,11 +25,14 @@ jobs:
2525 fetch-depth : 0
2626 - name : poor man's deploy
2727 run : |
28- # Create a temporary deploy key file in the workspace
29- mkdir -p $GITHUB_WORKSPACE/.deploy
30- echo "${{ secrets.FACITLITATOR_TESTING_DEPLOY_SSH_KEY }}" > $GITHUB_WORKSPACE/.deploy/deploy_key
31- chmod 600 $GITHUB_WORKSPACE/.deploy/deploy_key
28+ DEPLOY_KEY_FILE=$(mktemp)
29+ echo "${{ secrets.FACILITATOR_TESTING_DEPLOY_SSH_KEY }}" > "$DEPLOY_KEY_FILE"
30+ chmod 600 "$DEPLOY_KEY_FILE"
3231
33- GIT_SSH_COMMAND="ssh -i $GITHUB_WORKSPACE/.deploy/deploy_key -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null"
34- git remote add deploy ${{ secrets.FACITLITATOR_TESTING_DEPLOY_POORMANS_URL }}
35- git push deploy HEAD:master -f
32+ git remote add deploy ${{ vars.FACILITATOR_TESTING_DEPLOY_POORMANS_URL }}
33+ GIT_SSH_COMMAND="ssh -i $DEPLOY_KEY_FILE -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null" \
34+ git push deploy HEAD:master -f
35+
36+ export TAG=deployed-facilitator-testing-`date -u +"%Y-%m-%dT%H.%M.%S"`
37+ git tag $TAG
38+ git push origin $TAG
You can’t perform that action at this time.
0 commit comments