diff --git a/.github/workflows/secure-pipeline.yml b/.github/workflows/secure-pipeline.yml index e87c016..640462a 100644 --- a/.github/workflows/secure-pipeline.yml +++ b/.github/workflows/secure-pipeline.yml @@ -76,11 +76,11 @@ jobs: curl -s -L https://gist.github.com/raphabot/abae09b46c29afc7c3b918b7b8ec2a5c/raw/ | bash tmas scan registry:${DOCKER_IMAGE} -# - name: Deploy to GKE -# env: -# GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} -# VERSION: ${{ steps.version.outputs.VERSION }} -# run: | -# gcloud container clusters get-credentials igorsdevcluster --region us-central1 -# sed -i "s/GOOGLE_PROJECT/$GOOGLE_PROJECT/g" k8s/java-goof.yaml -# kubectl apply -f k8s/java-goof.yaml + - name: Deploy to GKE + env: + GOOGLE_PROJECT: ${{ secrets.GOOGLE_PROJECT }} + VERSION: ${{ steps.version.outputs.VERSION }} + run: | + gcloud container clusters get-credentials igorsdevcluster --region us-central1 + sed -i "s/GOOGLE_PROJECT/$GOOGLE_PROJECT/g; s/VERSION/$VERSION/g" k8s/java-goof.yaml + kubectl apply -f k8s/java-goof.yaml diff --git a/todolist-goof/k8s/java-goof.yaml b/todolist-goof/k8s/java-goof.yaml index e4e9388..e4c6996 100644 --- a/todolist-goof/k8s/java-goof.yaml +++ b/todolist-goof/k8s/java-goof.yaml @@ -22,7 +22,7 @@ spec: spec: containers: - name: java-goof - image: us-central1-docker.pkg.dev/GOOGLE_PROJECT/java-goof/java-goof:latest + image: us-central1-docker.pkg.dev/GOOGLE_PROJECT/java-goof/goof:VERSION ports: - containerPort: 8080 ---