-
Notifications
You must be signed in to change notification settings - Fork 0
62 lines (55 loc) · 1.64 KB
/
release.yml
File metadata and controls
62 lines (55 loc) · 1.64 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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: 'Semantic Release'
on:
push:
branches:
- main
- develop
permissions:
packages: write
id-token: write
issues: write
pull-requests: write
contents: write
jobs:
semantic-release:
name: 'Semantic Release'
runs-on: ubuntu-latest
defaults:
run:
shell: bash
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Semantic Release
id: semantic
uses: docker://ghcr.io/codfish/semantic-release-action@sha256:71048986f7e28f024cbad0ef106a7ef20b9b0d322f3a8aa51d89f1c424e75061
with:
branches: |
[
"main",
{
name: "develop",
prerelease: true
}
]
additional-packages: |
[
"@semantic-release/changelog@6.0.3",
"@semantic-release/git@10.0.1"
]
plugins: |
[
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/git"
]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Log in to GitHub Container Registry
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.actor }} --password-stdin
- name: Build and push Docker image
run: |
docker build -t ghcr.io/${{ github.repository }}:v${{ steps.semantic.outputs.release-version }} .
docker push ghcr.io/${{ github.repository }}:v${{ steps.semantic.outputs.release-version }}