Compare commits

..

3 commits

3 changed files with 8 additions and 4 deletions

View file

@ -19,7 +19,7 @@ begin
echo "{}" | sudo tee "$config" >/dev/null
echo "{}" | sudo tee "$overrides" >/dev/null
cp "$dir"/{ci.Dockerfile,docker-compose.core.yml,.dockerignore} "$root"
sudo cp "$dir"/{ci.Dockerfile,docker-compose.core.yml,.dockerignore} "$root"
echo "DRONE_JSONNET_ENABLED=true" | sudo tee "$root/server.common.env" >/dev/null
echo "DRONE_RUNNER_CAPACITY=2" | sudo tee "$root/runner.common.env" >/dev/null

View file

@ -1,4 +1,4 @@
set projectName port-valhalla
set nixPkgsVersion nixos-24.11
set nixPkgsVersion 566e53c2ad750c84f6d31f9ccb9d00f823165550
set valhallaCache ~/".cache/$projectName"
set nixPkgsCache "$valhallaCache/nixpkgs/$nixPkgsVersion"

View file

@ -11,8 +11,12 @@ begin
source "$config"
if ! __isNixModule "$nixPkgsCache"
mkdir -p "$nixPkgsCache"
and git clone https://github.com/NixOS/nixpkgs.git --depth=1 -b "$nixPkgsVersion" "$nixPkgsCache"
rm -rf "$nixPkgsCache"
and mkdir -p "$nixPkgsCache"
and git -C "$nixPkgsCache" init
and git -C "$nixPkgsCache" remote add origin https://github.com/NixOS/nixpkgs.git
and git -C "$nixPkgsCache" fetch origin "$nixPkgsVersion"
and git -C "$nixPkgsCache" reset --hard FETCH_HEAD
and rm -rf "$nixPkgsCache/.git"
end
end