forked from postmanlabs/httpbin
-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (41 loc) · 1.24 KB
/
release.yaml
File metadata and controls
49 lines (41 loc) · 1.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Deploy Release
on:
workflow_dispatch:
push:
branches:
- main
paths-ignore:
- k8s/**
env:
project: httpbin
jobs:
test:
uses: ./.github/workflows/testrunner.yaml
secrets: inherit
release:
runs-on: zon-ubuntu-general-dind
needs: test
permissions:
id-token: write
contents: write
steps:
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
- uses: ZeitOnline/gh-action-baseproject@4a35b6f8614aab8320249d6778ed6d2edd4a40c3 # v0.13.0
with:
project_name: ${{env.project}}
environment: production
gar_docker_auth: true
- uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # v6
with:
context: .
tags: ${{secrets.GAR_DOCKER_REGISTRY}}/${{env.project}}:${{github.sha}}
push: true
cache-from: type=gha
secrets: |
GCLOUD_TOKEN=${{steps.baseproject.outputs.gcloud_access_token}}
- name: Set image version
run: |
cd k8s/production
kustomize edit set image ${{secrets.GAR_DOCKER_REGISTRY}}/${{env.project}}:${{github.sha}}
git commit -am "Release image version ${{github.sha}}"
git push