Add CI for Build and Package of Parch Linux Docker
Some checks are pending
Build and Package of Parch Linux Docker / build (push) Waiting to run
Some checks are pending
Build and Package of Parch Linux Docker / build (push) Waiting to run
This commit is contained in:
parent
f6e9e71e0c
commit
79fda3fb9f
1 changed files with 33 additions and 0 deletions
33
.forgejo/workflows/ci.yml
Normal file
33
.forgejo/workflows/ci.yml
Normal file
|
@ -0,0 +1,33 @@
|
|||
name: Build and Package of Parch Linux Docker
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: archlinux
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set Docker registry mirror
|
||||
run: |
|
||||
echo '{ "registry-mirrors": ["https://docker-mirror.kubarcloud.com/"] }' | sudo tee /etc/docker/daemon.json
|
||||
sudo systemctl restart docker || true
|
||||
|
||||
- name: Install build dependencies
|
||||
run: |
|
||||
sudo pacman -Syu --noconfirm
|
||||
sudo pacman -S --noconfirm devtools git docker fakechroot fakeroot
|
||||
|
||||
- name: Create non-root builder user
|
||||
run: |
|
||||
sudo useradd -m builder || true
|
||||
echo 'builder ALL=(ALL) NOPASSWD: ALL' | sudo tee /etc/sudoers.d/builder
|
||||
|
||||
- name: Run make clean all as non-root
|
||||
run: |
|
||||
sudo -u builder make clean all
|
Loading…
Add table
Add a link
Reference in a new issue