-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit ef87856
Showing
2 changed files
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: Build Docker Container | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
docker: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Set BIRD version | ||
run: echo "BIRD_VERSION=$(curl -s 'https://dl.fedoraproject.org/pub/epel/9/Everything/x86_64/Packages/b/' | awk -F'"' '/>bird-/ {print $6; exit}' | sed -e 's/bird-//' -e 's/\.el.*.rpm//')" >> $GITHUB_ENV | ||
- name: Print target BIRD version | ||
run: echo $BIRD_VERSION | ||
- name: Build and push | ||
uses: docker/build-push-action@v6 | ||
with: | ||
push: true | ||
file: Containerfile | ||
build-args: | ||
- BIRD_VERSION=$BIRD_VERSION | ||
tags: ghcr.io/sonix-network/bird:$BIRD_VERSION |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
FROM docker.io/library/rockylinux:9 | ||
|
||
ARG BIRD_VERSION | ||
|
||
RUN echo $BIRD_VERSION |