Skip to content

Commit ef9ab22

Browse files
committed
.github/workflows: add build-fcode-utils-builder.yml action
This is a GitHub manual action that generates a container image from docker/Dockerfile.builder and pushes the result to ghcr.io/openbios/fcode-utils-builder:master for public use. Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
1 parent 9623b4c commit ef9ab22

1 file changed

Lines changed: 41 additions & 0 deletions

File tree

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Build fcode-utils-builder container
2+
3+
# Run manually from Actions tab
4+
on: [workflow_dispatch]
5+
6+
env:
7+
REGISTRY: ghcr.io
8+
IMAGE_NAME: ${{ github.repository }}-builder
9+
10+
jobs:
11+
build-x86_64:
12+
runs-on: ubuntu-latest
13+
permissions:
14+
contents: read
15+
packages: write
16+
17+
steps:
18+
- name: Checkout repository
19+
uses: actions/checkout@v2
20+
21+
- name: Log in to the Container registry
22+
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
23+
with:
24+
registry: ${{ env.REGISTRY }}
25+
username: ${{ github.actor }}
26+
password: ${{ secrets.GITHUB_TOKEN }}
27+
28+
- name: Extract metadata (tags, labels) for Docker
29+
id: meta
30+
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
31+
with:
32+
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
33+
34+
- name: Build and push Docker image
35+
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
36+
with:
37+
context: .
38+
file: docker/Dockerfile.builder
39+
push: true
40+
tags: ${{ steps.meta.outputs.tags }}
41+
labels: ${{ steps.meta.outputs.labels }}

0 commit comments

Comments
 (0)