Update car-demo-pipeline.yml #352
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
name: car-demo-common-service | |
on: | |
push: | |
branches: [ main ] | |
env: | |
PROJECT_ID: ${{ secrets.GKE_PROJECT }} | |
jobs: | |
setup-build-publish-deploy: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
id-token: write | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up JDK 19 | |
uses: actions/setup-java@v3 | |
with: | |
java-version: '19' | |
distribution: 'temurin' | |
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml | |
settings-path: ${{ github.workspace }} | |
- uses: 'google-github-actions/auth@v1' | |
with: | |
credentials_json: ${{ secrets.GKE_KEY }} | |
- uses: google-github-actions/setup-gcloud@v1 | |
with: | |
project_id: ${{ env.GKE_PROJECT }} | |
# Configure Docker to use the gcloud command-line tool as a credential | |
# helper for authentication | |
- name: configure docker | |
run: |- | |
gcloud --quiet auth configure-docker | |
- name: Debug Information | |
run: | | |
cat $GITHUB_WORKSPACE/settings.xml | |
env | |
- name: Build, Publish, and Deploy | |
run: | | |
. apps-deployment-script.sh "us-east1" | |
env: | |
#CUSTOM_TOKEN: ${{ secrets.CUSTOM_GITHUB_TOKEN_PAT }} | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |