java/java-guestbook/backend/skaffold.yaml (23 lines of code) (raw):
# To learn more about the skaffold.yaml schema visit
# https://skaffold.dev/docs/references/yaml/
apiVersion: skaffold/v2beta18
kind: Config
metadata:
name: backend
build:
# defines where to find the code at build time and where to push the resulting image
artifacts:
- image: java-guestbook-backend
# To learn more about how Jib builds Java containers visit
# https://github.com/GoogleContainerTools/jib
jib:
project: backend
context: ../
# defines the Kubernetes manifests to deploy on each run
deploy:
kubectl:
manifests:
- ./kubernetes-manifests/*.yaml
profiles:
# use the cloudbuild profile to build images using Google Cloud Build
- name: cloudbuild
build:
googleCloudBuild: {}
# use the dockerfile profile to build images using Docker instead of Jib
- name: dockerfile
build:
artifacts:
- image: java-guestbook-backend
context: .