-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (37 loc) · 1.21 KB
/
preview.yaml
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
name: Preview Image
on:
workflow_dispatch:
issue_comment:
types:
- created
jobs:
build:
runs-on: ubuntu-latest
if: github.event.issue.pull_request && contains(github.event.comment.body, '/build')
steps:
- uses: actions/checkout@v3
- name: Checkout Pull Request
if: github.event.issue.number
run: hub pr checkout ${{ github.event.issue.number }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/checkout@v3
with:
repository: itering/actions
path: .github/actions
persist-credentials: false
ssh-key: "${{ secrets.ITERING_ACTIONS_DEPLOY_KEY }}"
- uses: actions/setup-go@v3
with:
go-version: 1.18
- name: Build
run: make build
- uses: ./.github/actions/docker-build-deploy
with:
deploy_phase: staging
login_username: _json_key
login_password: ${{ secrets.GCR_SA_KEY }}
docker_registry: asia.gcr.io/${{ secrets.GCR_PROJECT_ID }}
trigger_token: ${{ secrets.ITERING_DEPLOYMENT_TRIGGER_TOKEN }}
trigger_endpoint: ${{ secrets.ITERING_DEPLOYMENT_TRIGGER_ENDPOINT }}
skip_deploy: true