-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (53 loc) · 2.02 KB
/
release.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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
name: Release
on:
workflow_dispatch:
push:
branches:
- main
jobs:
release:
name: Release
runs-on: ubuntu-latest
# Skip running release workflow on forks
if: github.repository_owner == 'wandb'
steps:
- name: Checkout
uses: actions/checkout@v2
with:
persist-credentials: false
fetch-depth: 0
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_TOKEN }}
- name: Versioning
id: release
uses: cycjimmy/semantic-release-action@v3
with:
semantic_version: 19.0.2
extra_plugins: |
@semantic-release/changelog@6.0.1
@semantic-release/git@10.0.1
conventional-changelog-conventionalcommits@4.6.3
env:
GITHUB_TOKEN: ${{ secrets.GH_SECRET }}
- uses: actions/setup-go@v4
with:
go-version: stable
- name: Build and Push
run: |
make docker-build docker-push
docker tag wandb/controller:latest wandb/controller:${{ steps.release.outputs.new_release_version }}
docker push wandb/controller:${{ steps.release.outputs.new_release_version }}
docker tag wandb/controller:latest wandb/controller:${{ steps.release.outputs.new_release_major_version }}.${{ steps.release.outputs.new_release_minor_version }}
docker push wandb/controller:${{ steps.release.outputs.new_release_major_version }}.${{ steps.release.outputs.new_release_minor_version }}
docker tag wandb/controller:latest wandb/controller:${{ steps.release.outputs.new_release_major_version }}
docker push wandb/controller:${{ steps.release.outputs.new_release_major_version }}
env:
IMAGE_TAG_BASE: wandb/controller
VERSION: latest