Skip to content

Commit

Permalink
Merge pull request #144 from gnosis/develop
Browse files Browse the repository at this point in the history
Fix ref key on the production deployment script
  • Loading branch information
giacomolicari authored Jul 29, 2021
2 parents abb668a + 1b23af5 commit 8bf0fb8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .github/scripts/prepare_production_deployment.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ set -e
# - Security env variables are available.
echo "🚀 Preparing version $VERSION_TAG for deployment"

if [ -n "$VERSION_TAG" ] && [ -n "$PROD_DEPLOYMENT_HOOK_TOKEN" ] && [ -n "$PROD_DEPLOYMENT_HOOK_URL" ]
if [ -n "$VERSION_TAG" ] && [ -n "$PROD_DEPLOYMENT_HOOK_TOKEN" ] && [ -n "$PROD_DEPLOYMENT_HOOK_URL" ] && [ -n "$REF_BRANCH" ]
then
curl --silent --output /dev/null --write-out "%{http_code}" -X POST \
-F token="$PROD_DEPLOYMENT_HOOK_TOKEN" \
-F ref=main \
-F ref=$REF_BRANCH \
-F "variables[TRIGGER_RELEASE_COMMIT_TAG]=$VERSION_TAG" \
$PROD_DEPLOYMENT_HOOK_URL
else
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ jobs:
if: startsWith(github.ref, 'refs/tags/')
run: echo ::set-output name=VERSION_TAG::${GITHUB_REF#refs/tags/}

- name: 'Prepare safe-apps-developer-ui for deploy to Production'
- name: 'Prepare safe-docs for deploy to Production'
if: startsWith(github.ref, 'refs/tags/v')
run: aws s3 sync website/build/safe-docs s3://${{ secrets.AWS_STAGING_BUCKET_NAME }}/releases/${{ github.event.release.tag_name }} --delete

Expand All @@ -64,3 +64,4 @@ jobs:
PROD_DEPLOYMENT_HOOK_TOKEN: ${{ secrets.PROD_DEPLOYMENT_HOOK_TOKEN }}
PROD_DEPLOYMENT_HOOK_URL: ${{ secrets.PROD_DEPLOYMENT_HOOK_URL }}
VERSION_TAG: ${{ steps.get_tag_version.outputs.VERSION_TAG }}
REF_BRANCH: master

0 comments on commit 8bf0fb8

Please sign in to comment.