Merge pull request #1486 from OKatrych/devfestwarsaw24 #686
This file contains 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
# Deploys to the backend | |
name: Backend Deploy | |
on: | |
push: | |
branches: | |
- 'main' | |
paths: | |
- 'backend/**' | |
- 'landing-page/**' | |
- 'build.gradle.kts' | |
- 'settings.gradle.kts' | |
- 'gradle/libs.versions.toml' | |
- 'gradle/wrapper/gradle-wrapper.properties' | |
- ".github/workflows/**" | |
- "buildSrc/**" | |
# Cancel any current or previous job from the same PR | |
concurrency: | |
group: backend-deploy-${{ github.head_ref }} | |
cancel-in-progress: true | |
jobs: | |
deploy: | |
runs-on: ubuntu-22.04 | |
if: github.repository == 'joreilly/Confetti' | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-java@v4 | |
with: | |
distribution: 'zulu' | |
java-version: 17 | |
- name: Setup Gradle | |
uses: gradle/[email protected] | |
- uses: hashicorp/setup-terraform@v3 | |
- name: Build | |
run: | | |
./gradlew :setupCredentials uploadLandingPage | |
./gradlew :backend:terraform:apply | |
./gradlew :backend:service-graphql:bumpCloudRunRevision | |
./gradlew :backend:service-import:bumpCloudRunRevision | |
env: | |
GOOGLE_SERVICES_JSON: ${{ secrets.GOOGLE_SERVICES_JSON }} | |
FIREBASE_SERVICES_JSON: ${{ secrets.FIREBASE_SERVICES_JSON }} | |
APOLLO_KEY: ${{ secrets.APOLLO_KEY }} |