Deploy Dev #2186
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Deploy Dev | |
| on: | |
| pull_request_target: | |
| types: | |
| - closed | |
| branches: | |
| - 'main' | |
| - 'release/**' | |
| paths: | |
| - ".github/workflows/**" | |
| - "client/**" | |
| - "server/**" | |
| - "database/**" | |
| - "docker/**" | |
| - "terraform/**" | |
| - "Dockerfile" | |
| - "Dockerfile_client" | |
| - "!**/README.md" | |
| workflow_dispatch: | |
| inputs: | |
| IMAGE_TAG: | |
| description: Full SHA or tag to deploy. Defaults to current commit SHA if 'latest'. | |
| required: false | |
| default: latest | |
| jobs: | |
| call-lambda-zip: | |
| uses: ./.github/workflows/lambda-zip.yml | |
| secrets: inherit | |
| with: | |
| ENVIRONMENT: DEV | |
| REGISTRY: ${{ vars.REGISTRY }} | |
| call-mvn-client: | |
| uses: ./.github/workflows/mvn-client.yml | |
| secrets: inherit | |
| with: | |
| ENVIRONMENT: DEV | |
| TAG: ${{inputs.IMAGE_TAG || format( 'pr-{0}', github.event.pull_request.number) }} | |
| wfnews-api-server-build: | |
| uses: ./.github/workflows/mvn-server.yml | |
| secrets: inherit | |
| with: | |
| PROJECT_NAME: wfnews-api | |
| ENVIRONMENT: DEV | |
| TAG: ${{inputs.IMAGE_TAG || format( 'pr-{0}', github.event.pull_request.number) }} | |
| wfone-notifications-api-server-build: | |
| uses: ./.github/workflows/mvn-server.yml | |
| secrets: inherit | |
| with: | |
| PROJECT_NAME: wfone-notifications-api | |
| ENVIRONMENT: DEV | |
| TAG: ${{inputs.IMAGE_TAG || format( 'pr-{0}', github.event.pull_request.number) }} | |
| wfone-notification-push-api-server-build: | |
| uses: ./.github/workflows/mvn-server.yml | |
| secrets: inherit | |
| with: | |
| PROJECT_NAME: wfone-notification-push-api | |
| ENVIRONMENT: DEV | |
| TAG: ${{inputs.IMAGE_TAG || format( 'pr-{0}', github.event.pull_request.number) }} | |
| wfss-pointid-api-server-build: | |
| uses: ./.github/workflows/mvn-server.yml | |
| secrets: inherit | |
| with: | |
| PROJECT_NAME: wfss-pointid-api | |
| ENVIRONMENT: DEV | |
| TAG: ${{inputs.IMAGE_TAG || format( 'pr-{0}', github.event.pull_request.number) }} | |
| liquibase-build: | |
| uses: ./.github/workflows/liquibase.yml | |
| secrets: inherit | |
| with: | |
| ENVIRONMENT: DEV | |
| TAG: ${{inputs.IMAGE_TAG || format( 'pr-{0}', github.event.pull_request.number) }} | |
| nginx-build: | |
| uses: ./.github/workflows/nginx.yml | |
| secrets: inherit | |
| with: | |
| ENVIRONMENT: DEV | |
| TAG: ${{inputs.IMAGE_TAG || format( 'pr-{0}', github.event.pull_request.number) }} | |
| sanitize-tag: | |
| runs-on: ubuntu-latest | |
| outputs: | |
| image-tag-sanitized: ${{ steps.sanitize.outputs.tag }} | |
| steps: | |
| - name: Sanitize tag | |
| id: sanitize | |
| run: | | |
| TAG="${{ inputs.IMAGE_TAG || format('pr-{0}', github.event.pull_request.number) }}" | |
| if [ "$TAG" == "latest" ] || [ -z "$TAG" ]; then | |
| TAG=$(echo ${{ github.sha }} | cut -c1-7) | |
| elif [ ${#TAG} -ge 40 ]; then | |
| TAG=$(echo $TAG | cut -c1-7) | |
| fi | |
| echo "tag=$(echo $TAG | sed 's/\//-/g')" >> $GITHUB_OUTPUT | |
| terragrunt-deploy-dev: | |
| uses: ./.github/workflows/terragrunt-deploy.yml | |
| needs: [call-lambda-zip, call-mvn-client, wfnews-api-server-build, wfone-notifications-api-server-build, liquibase-build, nginx-build, wfss-pointid-api-server-build, wfone-notification-push-api-server-build, sanitize-tag] | |
| with: | |
| DEFAULT_APPLICATION_ENVIRONMENT: DEV | |
| IMAGE_TAG: ${{ needs.sanitize-tag.outputs.image-tag-sanitized }} | |
| TARGET_ENV: dev | |
| MAX_RECEIVED_COUNT: 10 | |
| VISIBILITY_TIMEOUT_SECONDS: 100 | |
| PUSH_NOTIFICATION_AWS_USER: "" | |
| EVENT_BRIDGE_ARN: "" | |
| WFNEWS_URL: "" | |
| BAN_PROHIBITION_MONITOR_KEY: "" | |
| ACTIVE_FIRE_MONITOR_KEY: "" | |
| AREA_RESTRICTIONS_MONITOR_KEY: "" | |
| EVACUATION_MONITOR_KEY: "" | |
| LAMBDA_LAYER_KEY: "" | |
| secrets: inherit | |
| jmeter-test-dev: | |
| uses: ./.github/workflows/jmeter.yml | |
| needs: [terragrunt-deploy-dev] | |
| with: | |
| ENVIRONMENT: dev | |
| ios-deploy: | |
| uses: ./.github/workflows/ios.yml | |
| needs: [call-mvn-client] | |
| with: | |
| build_environment: DEV | |
| upload_to_app_store: true | |
| skip_slack_notification: false | |
| secrets: inherit | |
| android-deploy: | |
| uses: ./.github/workflows/android.yml | |
| needs: [call-mvn-client] | |
| with: | |
| build_environment: DEV | |
| upload_to_play_store: true | |
| increment_version_number: true | |
| skip_slack_notification: false | |
| secrets: inherit |