diff --git a/.github/workflows/pkg.yml b/.github/workflows/pkg.yml index 48d10d1e..4f3493ec 100644 --- a/.github/workflows/pkg.yml +++ b/.github/workflows/pkg.yml @@ -14,24 +14,24 @@ on: jobs: package: - uses: NLnetLabs/ploutos/.github/workflows/pkg-rust.yml@v1 + # See: https://github.com/NLnetLabs/ploutos + uses: NLnetLabs/ploutos/.github/workflows/pkg-rust.yml@v5 secrets: DOCKER_HUB_ID: ${{ secrets.DOCKER_HUB_ID }} DOCKER_HUB_TOKEN: ${{ secrets.DOCKER_HUB_TOKEN }} with: + cross_build_args: --features static-openssl + cross_max_wait_mins: 20 + docker_org: nlnetlabs docker_repo: krill + docker_build_rules: pkg/rules/docker-images-to-build.yml + docker_sanity_check_command: krillc --version - cross_build_rules_path: pkg/rules/cross-targets.yml - docker_build_rules_path: pkg/rules/docker-images-to-build.yml - package_build_rules_path: pkg/rules/packages-to-build.yml - package_test_rules_path: pkg/rules/packages-to-test.yml + package_build_rules: pkg/rules/packages-to-build.yml package_test_scripts_path: pkg/test-scripts/test-.sh - cross_build_args: --features static-openssl deb_extra_build_packages: libssl-dev - deb_maintainer: The NLnet Labs RPKI Team - docker_sanity_check_command: krillc --version - rpm_extra_build_packages: openssl-devel + rpm_extra_build_packages: make openssl-devel rpm_scriptlets_path: pkg/rpm/scriptlets.toml diff --git a/pkg/rules/cross-targets.yml b/pkg/rules/cross-targets.yml deleted file mode 100644 index 02bdfbf8..00000000 --- a/pkg/rules/cross-targets.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- -# must be one of: https://github.com/cross-rs/cross#supported-targets -# use MUSL targets for binaries intended to be included in Docker images -# as the Alpine base image we use has MUSL, not GNU LIBC. -- 'arm-unknown-linux-musleabihf' # for Docker -- 'armv7-unknown-linux-musleabihf' # for Docker -- 'aarch64-unknown-linux-musl' # for Docker - -# use GNU LIBC targets otherwise as Debian et al use GNU LIBC, not MUSL. -- 'arm-unknown-linux-gnueabihf' # for DEB -- 'armv7-unknown-linux-gnueabihf' # for DEB -- 'aarch64-unknown-linux-gnu' # for DEB diff --git a/pkg/rules/docker-images-to-build.yml b/pkg/rules/docker-images-to-build.yml index d6e63f77..57b04330 100644 --- a/pkg/rules/docker-images-to-build.yml +++ b/pkg/rules/docker-images-to-build.yml @@ -1,20 +1,5 @@ +# See: https://github.com/NLnetLabs/ploutos/blob/main/docs/docker_packaging.md#docker-build-rules --- -# matrix field notes: -# platform: used by Docker to use the right architecture base image. -# the set of supported values can be seen at: -# https://go.dev/doc/install/source#environment -# from: https://github.com/docker-library/official-images#architectures-other-than-amd64 -# from: https://docs.docker.com/desktop/multi-arch/ -# one must also take any "normalization" into account, e.g. arm64v8 -> arm64, see: -# https://github.com/containerd/containerd/blob/v1.4.3/platforms/database.go#L83 -# see also: -# https://stackoverflow.com/a/70889505 -# shortname: used by us to tag the architecture specific "manifest" image. -# crosstarget: (optional) used to download the correct cross-compiled binary that was produced earlier by the -# 'cross' job above. -# mode: (optional) set to 'copy' for cross-compiled targets. -# cargo_args: (optional) can be used when testing, e.g. set to '--no-default-features' to speed up the Krill -# build. include: - platform: "linux/amd64" shortname: "amd64" @@ -22,15 +7,15 @@ include: - platform: "linux/arm/v6" shortname: "armv6" - crosstarget: "arm-unknown-linux-musleabihf" + target: "arm-unknown-linux-musleabihf" mode: "copy" - platform: "linux/arm/v7" shortname: "armv7" - crosstarget: "armv7-unknown-linux-musleabihf" + target: "armv7-unknown-linux-musleabihf" mode: "copy" - platform: "linux/arm64" shortname: "arm64" - crosstarget: "aarch64-unknown-linux-musl" + target: "aarch64-unknown-linux-musl" mode: "copy" diff --git a/pkg/rules/packages-to-build.yml b/pkg/rules/packages-to-build.yml index 1ec47681..d220a40a 100644 --- a/pkg/rules/packages-to-build.yml +++ b/pkg/rules/packages-to-build.yml @@ -1,3 +1,4 @@ +# See: https://github.com/NLnetLabs/ploutos/blob/main/docs/os_packaging.md#package-build-rules --- pkg: - "krill" @@ -22,7 +23,7 @@ include: # `Cargo.toml`. - image: "centos:7" extra_build_args: "--features static-openssl" - systemd_service_unit_file: pkg/common/krill-ubuntu-xenial.krill.service + rpm_systemd_service_unit_file: pkg/common/krill-ubuntu-xenial.krill.service # CentOS 8 became EOL and is in theory still usable as a build container as there is still a Docker image # available, and package installation can be done by switching the yum config in the container to use packages @@ -35,7 +36,7 @@ include: # image we are building it in. - image: "rockylinux:8" os: "centos:8" - systemd_service_unit_file: "pkg/common/krill-ubuntu-focal.krill.service" + rpm_systemd_service_unit_file: "pkg/common/krill-ubuntu-focal.krill.service" # package for the Raspberry Pi 4b as an ARMv7 cross compiled variant of the Debian Bullseye upon which # Raspbian 11 is based. diff --git a/pkg/rules/packages-to-test.yml b/pkg/rules/packages-to-test.yml deleted file mode 100644 index 05ac7096..00000000 --- a/pkg/rules/packages-to-test.yml +++ /dev/null @@ -1,34 +0,0 @@ ---- -pkg: - - "krill" - - "krillup" -image: - - "ubuntu:xenial" # ubuntu/16.04 - - "ubuntu:bionic" # ubuntu/18.04 - - "ubuntu:focal" # ubuntu/20.04 - - "ubuntu:jammy" # ubuntu/22.04 - # - 'debian:stretch' # debian/9 - LXC image is no longer available on images.linuxcontainers.org - - "debian:buster" # debian/10 - - "debian:bullseye" # debian/11 - - "centos:7" - - "centos:8" -mode: - - "fresh-install" - - "upgrade-from-published" -target: - - "x86_64" -# if we later add a new O/S or variant we won't have yet ever published the package so can't do a test upgrade -# over last published version. In that case add lines here like so to disable the upgrade from published test -# for that O/S (remember to change debian:bullseye to the correct O/S name!): -# -# exclude: -# - image: 'debian:bullseye' -# mode: 'upgrade-from-published' -exclude: - - pkg: "krill" - mode: "upgrade-from-published" - image: "ubuntu:jammy" - - pkg: "krillup" - mode: "upgrade-from-published" - image: "ubuntu:jammy" # ubuntu/22.04 -