Skip to content

Commit

Permalink
Merge pull request #147 from MusicDin/feat/mint
Browse files Browse the repository at this point in the history
Add Linux Mint
  • Loading branch information
tomponline authored Apr 18, 2024
2 parents 70fedce + 0750e25 commit 9680912
Show file tree
Hide file tree
Showing 25 changed files with 92 additions and 47 deletions.
3 changes: 0 additions & 3 deletions .github/actions/image-setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@ inputs:
go-version:
description: Go version to install
default: 1.22.x
ssh-key:
description: LXD imagebuilder deployment key
required: true

runs:
using: composite
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-almalinux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Determine image types
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-alpine.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Determine image types
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-alt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Build image
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-amazonlinux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Build image
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-archlinux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Determine image types
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-busybox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Build image
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-centos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Determine image types
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-debian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Determine image types
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-devuan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Build image
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-fedora.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Determine image types
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-funtoo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Build image
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-gentoo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Determine image types
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-kali.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Build image
run: |
Expand Down
87 changes: 87 additions & 0 deletions .github/workflows/image-mint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
name: Build Linux Mint Images

on:
schedule:
# Run at 00:00 UTC daily.
- cron: '0 0 * * *'
workflow_dispatch:
inputs:
publish:
type: boolean
default: false
description: Publish built image

jobs:
mint:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
release:
- una
- virginia
variant:
- default
- cloud
architecture:
- amd64
env:
type: "container"
distro: "${{ github.job }}"
target: "${HOME}/build"

steps:
- uses: actions/checkout@v4

- name: Setup environment
uses: ./.github/actions/image-setup

- name: Build image
run: |
TIMEOUT=1800
YAML="${{ github.workspace }}/images/${{ env.distro }}.yaml"
ARCH="${{ matrix.architecture }}"
TYPE="${{ env.type }}"
RELEASE="${{ matrix.release}}"
SUITE="jammy"
if [ "${RELEASE}" = "una" ]; then
SUITE=focal
fi
./bin/build-distro "${YAML}" "${ARCH}" "${TYPE}" "${TIMEOUT}" "${{ env.target }}" \
-o image.architecture="${ARCH}" \
-o image.release=${{ matrix.release }} \
-o image.variant=${{ matrix.variant }} \
-o source.suite="${SUITE}"
- name: Print build artifacts
run: ls -lah "${{ env.target }}"

- name: Test container image
uses: ./.github/actions/image-test
if: contains(env.type, 'container')
with:
type: container
target: ${{ env.target }}
distro: ${{ env.distro }}
release: ${{ matrix.release }}
variant: ${{ matrix.variant }}

- name: Test VM image
uses: ./.github/actions/image-test
if: contains(env.type, 'vm')
with:
type: vm
target: ${{ env.target }}
distro: ${{ env.distro }}
release: ${{ matrix.release }}
variant: ${{ matrix.variant }}

- name: Upload image
uses: ./.github/actions/image-upload
if: github.event_name == 'schedule' || inputs.publish == true
with:
target: ${{ env.target }}
image_dir: "${{ env.distro }}/${{ matrix.release }}/${{ matrix.architecture }}/${{ matrix.variant }}"
ssh_private_key: "${{ secrets.LXD_INFRA_IMAGES_KEY }}"
2 changes: 0 additions & 2 deletions .github/workflows/image-nixos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Build image
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-openeuler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Determine image types
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-opensuse.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Determine image types
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-openwrt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Build image
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-oracle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Build image
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-rockylinux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Determine image types
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-slackware.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Build image
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Determine image types
run: |
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/image-voidlinux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@ jobs:

- name: Setup environment
uses: ./.github/actions/image-setup
with:
ssh-key: ${{ secrets.LXD_IMAGEBUILDER_KEY }}

- name: Build image
run: |
Expand Down
5 changes: 5 additions & 0 deletions images/mint.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
image:
distribution: "mint"

simplestream:
release_aliases:
una: 20.3
virginia: 21.3

source:
downloader: debootstrap
same_as: gutsy
Expand Down

0 comments on commit 9680912

Please sign in to comment.