Go back to generating BUILD

This commit is contained in:
Greg Hellings
2024-07-23 18:13:58 -05:00
parent 906666f836
commit 9652d54ee0
4 changed files with 8 additions and 2 deletions
+1
View File
@@ -26,3 +26,4 @@ cache
venv venv
.gitlab-ci-build.yml .gitlab-ci-build.yml
build.env
+2 -2
View File
@@ -63,7 +63,7 @@ hyperv-iso.amd64:
COMMAND: > COMMAND: >
packer build ${only} packer build ${only}
-var-file="${distro}" -var-file="${distro}"
-var build=${CI_COMMIT_TAG} -var build=${BUILD}
-var cpus=2 -var cpus=2
-var memory=4096 -var memory=4096
${EXCEPT} ${EXCEPT}
@@ -90,5 +90,5 @@ hyperv-iso.amd64:
tag_name: '$CI_COMMIT_TAG' tag_name: '$CI_COMMIT_TAG'
description: >- description: >-
Release $CI_COMMIT_TAG, found on [Vagrant Cloud](https://app.vagrantup.com/boxen/) Release $CI_COMMIT_TAG, found on [Vagrant Cloud](https://app.vagrantup.com/boxen/)
as version v${CI_COMMIT_TAG} as version v${BUILD}
+2
View File
@@ -17,6 +17,8 @@ generate:
artifacts: artifacts:
paths: paths:
- distros/**/*.pkrvars.hcl - distros/**/*.pkrvars.hcl
reports:
dotenv: build.env
script: nix run ".#generate" script: nix run ".#generate"
continue: continue:
+3
View File
@@ -154,6 +154,7 @@
name = "generate"; name = "generate";
runtimeInputs = with pkgs; [ runtimeInputs = with pkgs; [
bash bash
coreutils
curl curl
jq jq
pup pup
@@ -163,6 +164,8 @@
for vars in distros/**/*.pkrvars.hcl.sh; do for vars in distros/**/*.pkrvars.hcl.sh; do
bash "./''${vars}" bash "./''${vars}"
done done
BUILD="$(date "+%Y.%m.%d.%H")"
echo "BUILD=$BUILD" >> build.env
''; '';
}; };
shellcheck = pkgs.writeShellApplication { shellcheck = pkgs.writeShellApplication {