-
Notifications
You must be signed in to change notification settings - Fork 8
63 lines (58 loc) · 1.88 KB
/
upload_signed_sources.yml
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
name: Build and sign debian sources package
on:
workflow_dispatch:
# Inputs the workflow accepts.
inputs:
tar-url:
description: 'URL for Kolibri tar file'
required: true
workflow_call:
inputs:
tar-file-name:
required: true
type: string
ref:
description: 'A ref for this workflow to check out its own repo'
required: true
type: string
secrets:
GPG_SIGNING_KEY:
required: true
GPG_PASSPHRASE:
required: true
jobs:
upload_deb:
name: Build sign and upload sources for deb file
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
if: ${{ !inputs.ref }}
- uses: actions/checkout@v4
if: ${{ inputs.ref }}
with:
repository: learningequality/kolibri-installer-debian
ref: ${{ inputs.ref }}
- uses: actions/cache@v4
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('setup.py', 'build_requires.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Download the tarfile from URL
if: ${{ github.event.inputs.tar-url }}
run: make get-tar tar=${{ github.event.inputs.tar-url }}
- name: Download the tarfile from artifacts
if: ${{ inputs.tar-file-name }}
uses: actions/download-artifact@v4
with:
name: ${{ inputs.tar-file-name }}
path: build_src
- name: Install Debian build package dependencies
run: sudo apt install -y devscripts debhelper python3-pip dput dh-python python3-all python3-pytest
- name: Configure GPG Key
run: |
echo -n "${{ secrets.GPG_SIGNING_KEY }}" | base64 --decode | gpg --import --no-tty --batch --yes
- name: Build and upload debianized sources release files to Launchpad
env:
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
run: make commit-new-release