From ce8d488c829f9e009e8f0cc8b76de8c7f5209c48 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Gonz=C3=A1lez?= <36533965+victorggonzalez@users.noreply.github.com> Date: Mon, 11 Jul 2022 17:05:18 +0200 Subject: [PATCH] feat: add cdeployment caller workflow --- .github/workflows/cdeployment-s3-caller.yml | 36 +++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .github/workflows/cdeployment-s3-caller.yml diff --git a/.github/workflows/cdeployment-s3-caller.yml b/.github/workflows/cdeployment-s3-caller.yml new file mode 100644 index 000000000..e2cde2ae8 --- /dev/null +++ b/.github/workflows/cdeployment-s3-caller.yml @@ -0,0 +1,36 @@ +name: Deploy to production environment + +# Controls when the action will run +on: + # Triggers the workflow on repository-dispatch event + repository_dispatch: + types: [production-deployment] + +# This workflow is made up of one job that calls the reusable workflow in graasp-deploy +jobs: + graasp-deploy-s3-workflow: + # Replace with repository name + name: Graasp Builder + # Replace 'main' with the hash of a commit, so it points to an specific version of the reusable workflow that is used + # Reference reusable workflow file. Using the commit SHA is the safest for stability and security + uses: graasp/graasp-deploy/.github/workflows/cdeployment-s3.yml@5976045215b3db442504fdfecf3255fcb5d96fab + # Replace input build-folder if needed. + with: + build-folder: 'build' + tag: ${{ github.event.client_payload.tag }} + # Insert required secrets based on repository with the following format: ${{ secrets.SECRET_NAME }} + secrets: + aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_PROD }} + aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_PROD }} + aws-region: ${{ secrets.AWS_REGION_PROD }} + aws-s3-bucket-name: ${{ secrets.AWS_S3_BUCKET_NAME_GRAASP_COMPOSE_PROD }} + cloudfront-distribution-id: ${{ secrets.CLOUDFRONT_DISTRIBUTION_GRAASP_COMPOSE_PROD }} + api-host: ${{ secrets.REACT_APP_API_HOST_PROD }} + show-notifications: ${{ secrets.REACT_APP_SHOW_NOTIFICATIONS }} + authentication-host: ${{ secrets.REACT_APP_AUTHENTICATION_HOST_PROD }} + graasp-perform-host: ${{ secrets.REACT_APP_GRAASP_PERFORM_HOST_PROD }} + graasp-explorer-host: ${{ secrets.REACT_APP_GRAASP_EXPLORE_HOST_PROD }} + graasp-analyzer-host: ${{ secrets.REACT_APP_GRAASP_ANALYZER_HOST_PROD }} + ga-measurement-id: ${{ secrets.REACT_APP_GA_MEASUREMENT_ID_PROD }} + hidden-item-tag-id: ${{ secrets.REACT_APP_HIDDEN_ITEM_TAG_ID_PROD }} + domain: ${{ secrets.REACT_APP_DOMAIN_PROD }}