32
32
33
33
jobs :
34
34
35
- build_and_release :
36
- name : Build and Release ${{ matrix.build-image-name }}
35
+ tag :
36
+ name : Tagging
37
37
runs-on : ubuntu-24.04
38
- strategy :
39
- matrix :
40
- include :
41
- - containerfile : " ./chat/base/Containerfile"
42
- build-image-name : " ai-lab-playground-chat"
43
- archs : amd64, arm64
44
- - containerfile : " ./chat/vulkan/amd64/Containerfile"
45
- build-image-name : " ai-lab-playground-chat-vulkan"
46
- archs : amd64
47
- - containerfile : " ./chat/vulkan/arm64/Containerfile"
48
- build-image-name : " ai-lab-playground-chat-vulkan"
49
- archs : arm64
50
- - containerfile : " ./chat/cuda/amd64/Containerfile"
51
- build-image-name : " ai-lab-playground-chat-cuda"
52
- archs : amd64
38
+ outputs :
39
+ githubTag : ${{ steps.TAG_UTIL.outputs.githubTag}}
40
+ imageVersion : ${{ steps.TAG_UTIL.outputs.imageVersion}}
41
+ imageVersionShort : ${{ steps.TAG_UTIL.outputs.imageVersionShort}}
42
+
53
43
steps :
54
44
- uses : actions/checkout@v4
55
45
with :
56
46
ref : ${{ github.event.inputs.branch }}
57
-
58
47
- name : Generate tag utilities
59
48
id : TAG_UTIL
60
49
run : |
@@ -69,19 +58,32 @@ jobs:
69
58
70
59
echo "Tagging with ${{ steps.TAG_UTIL.outputs.githubTag }}"
71
60
git tag ${{ steps.TAG_UTIL.outputs.githubTag }}
72
- git push origin ${{ steps.TAG_UTIL.outputs.githubTag }}
61
+ git push origin ${{ steps.TAG_UTIL.outputs.githubTag }}
73
62
74
- - name : Create Release
75
- id : create_release
76
- uses : ncipollo/release-action@v1
77
- env :
78
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
63
+ build :
64
+ name : Build and Release ${{ matrix.build-image-name }}
65
+ needs : tag
66
+ runs-on : ubuntu-24.04
67
+ strategy :
68
+ matrix :
69
+ include :
70
+ - containerfile : " ./chat/base/Containerfile"
71
+ build-image-name : " ai-lab-playground-chat"
72
+ archs : amd64, arm64
73
+ - containerfile : " ./chat/vulkan/amd64/Containerfile"
74
+ build-image-name : " ai-lab-playground-chat-vulkan"
75
+ archs : amd64
76
+ - containerfile : " ./chat/vulkan/arm64/Containerfile"
77
+ build-image-name : " ai-lab-playground-chat-vulkan"
78
+ archs : arm64
79
+ - containerfile : " ./chat/cuda/amd64/Containerfile"
80
+ build-image-name : " ai-lab-playground-chat-cuda"
81
+ archs : amd64
82
+ steps :
83
+ - uses : actions/checkout@v4
79
84
with :
80
- tag : ${{ steps.TAG_UTIL.outputs.githubTag }}
81
- name : ${{ steps.TAG_UTIL.outputs.githubTag }}
82
- draft : true
83
- prerelease : false
84
-
85
+ ref : ${{ needs.tag.outputs.githubTag }}
86
+
85
87
- name : Install qemu dependency
86
88
run : |
87
89
sudo apt-get update
92
94
uses : redhat-actions/buildah-build@v2
93
95
with :
94
96
image : ${{ matrix.build-image-name }}
95
- tags : latest ${{ steps.TAG_UTIL .outputs.imageVersion }} ${{ steps.TAG_UTIL .outputs.imageVersionShort }}
96
- labels : io.podman.ai-lab.version=${{ steps.TAG_UTIL .outputs.imageVersion }}
97
+ tags : latest ${{ needs.tag .outputs.imageVersion }} ${{ needs.tag .outputs.imageVersionShort }}
98
+ labels : io.podman.ai-lab.version=${{ needs.tag .outputs.imageVersion }}
97
99
containerfiles : |
98
100
${{ matrix.containerfile }}
99
101
context : ./chat
@@ -114,14 +116,18 @@ jobs:
114
116
image : ${{ steps.build-image.outputs.image }}
115
117
tags : ${{ steps.build-image.outputs.tags }}
116
118
registry : ghcr.io/${{ github.repository_owner }}/podman-desktop-extension-ai-lab-playground-images
117
-
118
- - name : id
119
- run : echo the release id is ${{ steps.create_release.outputs.id}}
120
-
121
- - name : Publish release
122
- uses : StuYarrow/publish-release@v1.1.2
119
+
120
+ release :
121
+ needs : [tag, build]
122
+ name : Release
123
+ runs-on : ubuntu-24.04
124
+ steps :
125
+ - name : Create Release
126
+ id : create_release
127
+ uses : ncipollo/release-action@v1
123
128
env :
124
129
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
125
130
with :
126
- id : ${{ steps.create_release.outputs.id}}
131
+ tag : ${{ needs.tag.outputs.githubTag }}
132
+ name : ${{ needs.tag.outputs.githubTag }}
127
133
0 commit comments