Skip to content
This repository has been archived by the owner on Nov 20, 2023. It is now read-only.

Commit

Permalink
feat: declare base image and fedora ver in recipe
Browse files Browse the repository at this point in the history
  • Loading branch information
xynydev committed Apr 3, 2023
1 parent 5947af4 commit fe16187
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 3 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ jobs:
- name: Gather image data from recipe
run: |
echo "IMAGE_NAME=$(yq '.name' ./recipe.yml)" >> $GITHUB_ENV
echo "FEDORA_MAJOR_VERSION=$(yq '.fedora-version' ./recipe.yml)" >> $GITHUB_ENV
echo "BASE_CONTAINER_URL=$(yq '.base-container' ./recipe.yml)" >> $GITHUB_ENV
- name: Generate tags
id: generate-tags
Expand Down Expand Up @@ -113,7 +115,8 @@ jobs:
tags: |
${{ steps.generate-tags.outputs.alias_tags }}
build-args: |
FEDORA_MAJOR_VERSION=${{ matrix.major_version }}
FEDORA_MAJOR_VERSION=${{ env.FEDORA_MAJOR_VERSION }}
BASE_CONTAINER_URL=${{ env.BASE_CONTAINER_URL }}
labels: ${{ steps.meta.outputs.labels }}
oci: false

Expand Down
4 changes: 2 additions & 2 deletions Containerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
ARG FEDORA_MAJOR_VERSION=37
ARG BASE_CONTAINER_URL=ghcr.io/ublue-os/silverblue-main

# change this line if you want to change the image
FROM ghcr.io/ublue-os/silverblue-main:${FEDORA_MAJOR_VERSION}
FROM ${BASE_CONTAINER_URL}:${FEDORA_MAJOR_VERSION}

# copy over configuration files
COPY etc /etc
Expand Down
9 changes: 9 additions & 0 deletions recipe.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,13 @@
# the image will be at ghcr.io/yourusername/name
name: startingpoint

# what native container image to build on top of
# images not built by ublue might function unexpectly
base-container: ghcr.io/ublue-os/silverblue-main

# what fedora version to use, you can just change this to update
fedora-version: 37

rpms:
- python3-pip # needed for yafti
flatpaks:
Expand Down

0 comments on commit fe16187

Please sign in to comment.