Upgrade CI pipeline, fix static builds #345
No reviewers
Labels
No labels
action
check-aws
action
discussion-needed
action
for-external-contributors
action
for-newcomers
action
more-info-needed
action
need-funding
action
triage-required
kind
correctness
kind/experimental
kind
ideas
kind
improvement
kind
performance
kind
testing
kind
usability
kind
wrong-behavior
prio
critical
prio
low
scope
admin-api
scope
admin-sdk
scope
background-healing
scope
build
scope
documentation
scope
k8s
scope
layout
scope
metadata
scope
ops
scope
rpc
scope
s3-api
scope
security
scope
telemetry
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: Deuxfleurs/garage#345
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "ci/bump-nix-img"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Changelog:
[X] Change runner requirements, we don't need specific runners anymore for Nix (you can drop the Nix tag, the volume mount and do not need to perform manual warmup anymore)nix-build -A pkgs.amd64.release
now. This is closer to how Nix Flakes work.nix-build
(nix-build -A clippy.amd64
). It has 2 benefits compared to running clippy from a nix shell: 1. it leverages Nix caching 2. it builds a working binary that can be directly used intest-smoke.sh
.cargo2nix
that fixes this bug: https://github.com/cargo2nix/cargo2nix/issues/238 - When we have a complex project + a crate (eg. openssl) that has some "propagated build inputs", cargo2nix tends to duplicate similar values. In the end, the openssl propagated build inputs was repeated thousand of times. My patch to fix the bug:486675c672
. Later, I plan to bump cargo2nix on Garage, port this patch, and at the same time open a PR to upstream it.nix-daemon
. They have many benefits over the prior builder:nix maintenance
step is not needed anymore in Dronenix-build
are now sandboxed, so builds are even more reproducible/nix/store
. One of this change would make our nix operations 100% sandboxed and isolated from one another.Instructions to setup a new runner can be found here: https://git.deuxfleurs.fr/Deuxfleurs/infrastructure/src/branch/main/app/drone-ci/integration#install-the-runner
684019c7fa
tofcb04843f7
@ -26,3 +26,2 @@
commands:
- cp nix/nix.conf /etc/nix/nix.conf
- nix-build --no-build-output --no-out-link shell.nix --arg release false -A inputDerivation
- "[ -d /mnt/store/3vpyn2qz5ay057nq9x68sh0r328d77ng-nix-2.8.1/ ] || (mkdir -p /mnt/store && cp -r /nix/store/* /mnt/store/)"
What if the image
nixos-22.05
is updated and the hash3vpyn2qz5ay057nq9x68sh0r328d77ng-nix-2.8.1
changes? We don't want to copy files uselessly every time. Could we find another solution to detect whether the copy needs to be made? For instance we could have a custom file name and justtouch
it after copying files.OR: freeze the docker image using a hash and not a tag
Solved by changing how we handle Nix runners
1b79852e64
toa20a55efa9
Upgrade CI pipeline, fix static buildsto WIP: Upgrade CI pipeline, fix static builds19cd8ae752
to3ef9b3a650
3ef9b3a650
toa184f0d0b5
WIP: Upgrade CI pipeline, fix static buildsto Upgrade CI pipeline, fix static builds