-
Notifications
You must be signed in to change notification settings - Fork 15
67 lines (57 loc) · 1.58 KB
/
preseed.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
# vim:ts=2:sts=2:sw=2:et
#
# Author: Hari Sekhon
# Date: 2023-05-31 01:49:54 +0100 (Wed, 31 May 2023)
#
# https://github.com/HariSekhon/Templates
#
# License: see accompanying Hari Sekhon LICENSE file
#
# If you're using my code you're welcome to connect with me on LinkedIn and optionally send me feedback to help steer this or other code I publish
#
# https://www.linkedin.com/in/HariSekhon
#
# ============================================================================ #
# D e b i a n P r e s e e d
# ============================================================================ #
---
name: Debian Preseed
on:
workflow_call:
inputs:
files:
description: The preseed.cfg file paths to validate, separated by spaces
type: string
required: false
default: preseed.cfg
permissions:
contents: read
concurrency:
group: ${{ github.ref }}-${{ github.workflow }}
cancel-in-progress: true
defaults:
run:
shell: bash -euxo pipefail {0}
env:
DEBIAN_FRONTEND: noninteractive
jobs:
preseed:
name: Preseed
timeout-minutes: 10
runs-on: ubuntu-latest
container: debian
steps:
- uses: actions/checkout@v3
#name: Git Checkout # better to show the action@version
- name: Install Debconf
run: |
apt-get update
apt-get install debconf -y
- name: Validate Preseed
run: |
for file in ${{ inputs.files }}; do
echo "Validating $file"
echo
debconf-set-selections -c "$file"
echo
done