@@ -49,26 +49,39 @@ jobs:
49
49
sudo rm -rf "$AGENT_TOOLSDIRECTORY"
50
50
51
51
52
+
53
+ - uses : docker/setup-buildx-action@v3
54
+
55
+ - name : Login to Container Registry
56
+ if : github.ref == 'refs/heads/main'
57
+ run : |
58
+ docker login ${{ env.REGISTRY }} -u ${{ secrets.REGISTRY_USER }} -p ${{ secrets.REGISTRY_PASSWORD }}
59
+
60
+ - name : Extract metadata (tags, labels) for gotbot image
61
+ id : ilab_meta
62
+ uses : docker/metadata-action@v5
63
+ with :
64
+ images : |
65
+ ${{ env.REGISTRY }}/${{ env.REGISTRY_ORG }}/instructlab-${{ matrix.make_target }}
52
66
53
67
- name : Make Instructlab
54
68
run : make instructlab
55
69
working-directory : ./training/instructlab
56
70
57
- - name : Checkout buildah codebase
58
- id : checkout-buildah
59
-
71
+ - name : Build and push ilab images
72
+ uses : docker/build-push-action@v5
73
+ working-directory :
60
74
with :
61
- repository : containers/buildah
62
- path : buildah
63
- ref : ' main'
64
-
65
- - name : Setup Buildah v1.36
66
- working-directory : buildah
67
- run : |
68
- sudo apt-get -y -qq update
69
- sudo apt-get -y install bats btrfs-progs git go-md2man golang libapparmor-dev libglib2.0-dev libgpgme11-dev libseccomp-dev libselinux1-dev make skopeo
70
- make runc all SECURITYTAGS="apparmor seccomp"
71
- sudo make install install.runc
75
+ context : ./training/instructlab/instructlab
76
+ platforms : linux/amd64
77
+ build-args : |
78
+ GIT_TAG=stable
79
+ push : false
80
+ tags : ${{ steps.ilab_meta.outputs.tags }}
81
+ labels : ${{ steps.ilab_meta.outputs.labels }}
82
+ # cache-from: type=gha
83
+ # cache-to: type=gha,mode=max
84
+ file : ./training/instructlab/${{ matrix.containerfile_path }}
72
85
73
86
- name : Build Image
74
87
id : build_image
83
96
instructlab/
84
97
85
98
86
- - name : Login to Container Registry
87
- if : github.event_name == 'push' && github.ref == 'refs/heads/main'
88
- uses :
redhat-actions/[email protected]
89
- with :
90
- registry : ${{ env.REGISTRY }}
91
- username : ${{ secrets.REGISTRY_USER }}
92
- password : ${{ secrets.REGISTRY_PASSWORD }}
93
-
94
- - name : Push image
95
- if : github.event_name == 'push' && github.ref == 'refs/heads/main'
96
- uses :
redhat-actions/[email protected]
97
- with :
98
- image : ${{ steps.build_image.outputs.image }}
99
- tags : ${{ steps.build_image.outputs.tags }}
100
- registry : ${{ env.REGISTRY }}
101
99
102
100
- name : Publish Job Results to Slack
103
101
id : slack
0 commit comments