Skip to content

Build docker

Build docker #28

name: Build docker
on:
workflow_dispatch:
jobs:
deploy:
name: Build docker
runs-on: ubuntu-latest
permissions:
contents: write
packages: write
id-token: write # needed for signing the images with GitHub OIDC Token **not production ready**
env:
ENV: qa
VAULT_PREFIX: in2
DEPLOYMENT_NAME: keda
RELEASE_NAME: keda
GCP_PROJECT_ID: dev-in2
GCP_REGION: asia-south1
GCP_NAMESPACE: ion2
GCP_CLUSTER: dev-in2
DOCKER_GIT_TOKEN: ${{ secrets.DOCKER_GIT_TOKEN }}
container: ghcr.io/kedacore/build-tools:1.17.13
steps:
- name: Set up Repo Cloud SDK
uses: google-github-actions/[email protected]
with:
project_id: ${{ env.GCP_PROJECT_ID }}
service_account_key: ${{ secrets.GKE_SA_KEY }}
export_default_credentials: true
- name: Checkout
uses: actions/checkout@v3
with:
# ref: ${{ github.event.pull_request.head.ref }}
fetch-depth: 1
token: ${{ secrets.DOCKER_GIT_TOKEN }}
- name: Set up Dev Cloud SDK
uses: google-github-actions/[email protected]
with:
service_account_key: ${{ secrets.GCP_DEV_SA_KEY }}
export_default_credentials: true
- name: Register workspace path
run: git config --global --add safe.directory "/__w/keda/keda"
- name: Go modules sync
run: go mod tidy -compat=1.20
- name: Get the version
id: get_version
run: echo ::set-output name=VERSION::$(./version.sh)
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Docker configuration
run: |-
gcloud --quiet auth configure-docker
- name: Publish KEDA images
run: make publish
env:
VERSION: ${{ steps.get_version.outputs.VERSION }}
IMAGE_REGISTRY: gcr.io/dev-in-309805
IMAGE_REPO: 100mslive