st/.woodpecker.yml

29 lines
760 B
YAML
Raw Normal View History

2022-01-02 11:02:36 +01:00
branches: master
2022-03-05 10:30:18 +01:00
platform: linux/amd64
2022-01-02 11:02:36 +01:00
2022-01-02 11:00:02 +01:00
when:
event: push
pipeline:
build:
image: 'archlinux:latest'
commands:
# Update packages
- pacman -Syu --needed --noconfirm base-devel
# Create non-root user to perform build & switch to their home
- groupadd -g 1000 builder
- useradd -mg builder builder
- chown -R builder:builder "$PWD"
- "echo 'builder ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers"
- su builder
# Build the package
- MAKEFLAGS="-j$(nproc)" makepkg -s --noconfirm --needed
publish:
image: 'archlinux:latest'
commands:
# Publish the package
2022-02-02 11:18:22 +01:00
- 'curl -s -XPOST -H "X-API-KEY: $API_KEY" -T "$(ls *.pkg*)" https://arch.r8r.be/publish'
2022-01-02 11:00:02 +01:00
secrets:
- api_key