-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathaction.yml
More file actions
137 lines (137 loc) · 4.27 KB
/
action.yml
File metadata and controls
137 lines (137 loc) · 4.27 KB
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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
---
# yamllint disable rule:line-length
name: Create APT repository
description: Create APT repository using reprepro
branding:
icon: package
color: purple
inputs:
repo-name:
description: >-
Repository name.
required: true
scan-dir:
description: >-
Scan this directory for packages to include in the repo.
If unset, defaults to ${PWD}.
keyring-name:
description: >-
Keyring name. If unset, defaults to repo-name-keyring.
origin:
description: >-
Origin. If unset, defaults to repo-name.
suite:
description: >-
Suite. If unset, defaults to repo-name.
label:
description: >-
Label. If unset, defaults to repo-name.
codename:
description: >-
Codename. If unset, defaults to repo-name.
components:
description: >-
Components. If unset, defaults to main.
default: main
architectures:
description: >-
Architectures. If unset, defaults to amd64.
section:
description: >-
Section (Optional)
priority:
description: >-
Priority (Optional)
limit:
description: >-
How many package versions to keep.
If unset, defaults to 0 (unlimited).
signing-key:
description: >-
Private gpg key for signing.
Please use Secrets!
required: true
signing-key-passphrase:
description: >-
Passphrase for private gpg signing key.
Please use Secrets!
import-from-repo-url:
description: >-
Import existing packages from this repo url.
Workaround for immutable GH actions cache.
import-from-repo-regex:
description: >-
Regex to apply to imported packages, e.g. filter for `^.*arm64.*\.deb`.
import-from-repo-failure-allow:
description: >-
Do not fail on import errors (e.g. first run).
maintainer:
description: >-
Package maintainer for keyring package.
If unset, defaults to apt-repo-action@${GITHUB_REPOSITORY_OWNER}
homepage:
description: >-
Homepage for keyring package.
If unset, defaults to ${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}
override:
description: >-
Optional override file (see [man page](https://manpages.debian.org/unstable/reprepro/reprepro.1.en.html#OVERRIDE_FILES))
outputs:
dir:
description: >-
Directory which contains the APT repo.
value: ${{ steps.create-apt-repo.outputs.dir }}
keyring:
description: >-
Keyring name.
value: ${{ steps.create-apt-repo.outputs.keyring }}
runs:
using: composite
steps:
- name: Setup reprepro debian repository
uses: myci-actions/add-deb-repo@11
with:
repo: deb https://packaging.gitlab.io/reprepro-multiple-versions noble main
repo-name: reprepro-multiple-versions
keys-asc: https://packaging.gitlab.io/reprepro-multiple-versions/gpg.key
update: true
- name: Install reprepro
uses: awalsh128/cache-apt-pkgs-action@v1.4.3
with:
packages: apt-mirror apt-transport-https reprepro
- name: Install nfpm
uses: robinraju/release-downloader@v1.11
with:
repository: goreleaser/nfpm
fileName: '*Linux_x86_64.tar.gz'
latest: true
extract: true
out-file-path: "/tmp/"
- name: Import from APT repo
id: import-from-apt-repo
run: ${{ github.action_path }}/import.sh
shell: bash
env:
IMPORT_FROM_REPO: ${{ inputs.import-from-repo-url }}
IMPORT_FROM_REPO_REGEX: ${{ inputs.import-from-repo-regex }}
IMPORT_FROM_REPO_FAILURE_ALLOW: ${{ inputs.import-from-repo-failure-allow }}
- name: Create APT repo
id: create-apt-repo
run: ${GITHUB_ACTION_PATH}/repo.sh
shell: bash
env:
REPO_NAME: ${{ inputs.repo-name }}
SCAN_DIR: ${{ inputs.scan-dir }}
KEYRING_NAME: ${{ inputs.keyring-name }}
ORIGIN: ${{ inputs.origin }}
SUITE: ${{ inputs.suite }}
LABEL: ${{ inputs.label }}
CODENAME: ${{ inputs.codename }}
COMPONENTS: ${{ inputs.components }}
ARCHITECTURES: ${{ inputs.architectures }}
LIMIT: ${{ inputs.limit }}
SIGNING_KEY: ${{ inputs.signing-key }}
SIGNING_KEY_PASSPHRASE: ${{ inputs.signing-key-passphrase }}
MAINTAINER: ${{ inputs.maintainer }}
HOMEPAGE: ${{ inputs.homepage }}
OVERRIDE: ${{ inputs.override }}