-
Notifications
You must be signed in to change notification settings - Fork 43
/
snapcraft.yaml
74 lines (73 loc) · 2.17 KB
/
snapcraft.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
68
69
70
71
72
73
74
name: core24
# version: "24"
adopt-info: bootstrap
summary: Runtime environment based on Ubuntu 24.04
description: |
The base snap based on the Ubuntu 24.04 release.
confinement: strict
type: base
build-base: core24
grade: stable
assumes: [snapd2.55.5]
parts:
base:
plugin: nil
source: keyrings
build-packages:
- wget
build-environment:
- RELEASE: "24.04"
- DOT_RELEASE: "1"
- BASE: ubuntu-base-${RELEASE}${DOT_RELEASE:+.$DOT_RELEASE}-base-${CRAFT_ARCH_BUILD_FOR}.tar.gz
- DIR_URL: https://cdimage.ubuntu.com/ubuntu-base/releases/${RELEASE}/release
- URL: ${DIR_URL}/${BASE}
- SHA256: ${DIR_URL}/SHA256SUMS
- SIG: ${SHA256}.gpg
override-pull: |
craftctl default
wget "${SHA256}" "${SIG}" "${URL}"
gpg --no-default-keyring \
--keyring ./cd-image-keying.gpg \
--verify SHA256SUMS.gpg SHA256SUMS
awk -v "file=${BASE}" '$2=="*"file' SHA256SUMS | sha256sum -c
override-build: |
mkdir -p "${CRAFT_PART_INSTALL}/base"
tar -x --xattrs-include=* -f "${BASE}" -C "${CRAFT_PART_INSTALL}/base"
override-stage: |
rm -rf "${CRAFT_STAGE}/base"
craftctl default
override-prime: |
# Do nothing
splash-theme:
plugin: dump
source: https://github.com/snapcore/plymouth-theme-ubuntu-core.git
source-type: git
organize:
ubuntu-core: usr/share/plymouth/themes/ubuntu-core
copyright: usr/share/doc/plymouth-theme-ubuntu-core/copyright
stage:
- -README.md
bootstrap:
after:
- base
plugin: make
source: .
build-packages:
- shellcheck
- distro-info
- python3-debian
- python3-requests
- python3-yaml
# to generate changelogs, it's own snap need to be present,
# obviously for new core bases this cannot be the case, and
# we need to wait until the first release with introducing
# changelogs.
build-snaps:
- core24=latest/beta
override-pull: |
craftctl set version="$(/bin/date +%Y%m%d)"
craftctl default
override-prime: |
craftctl default
# ensure build-in tests are run
cd ${CRAFT_PART_SRC} && make test TESTDIR=${CRAFT_PRIME}