mirror of
https://github.com/foo-dogsquared/nixos-config.git
synced 2025-01-30 22:57:55 +00:00
apps/run-workflow-with-vm: update to 2024-05-10
This commit is contained in:
parent
177364306a
commit
08b1cf8df3
@ -16,7 +16,7 @@ When run, it should build a VM with its script to easily initialize it.
|
||||
|
||||
== Extra niceties
|
||||
|
||||
There's some niceties left with this script including the ability to include your own config by overriding `extra-config` as part of the include path.
|
||||
There's some niceties left with this script including the ability to include your own set of modules by overriding `extra-config` as part of the include path.
|
||||
It is expected that the extra configuration folder is structured similarly to this NixOS cluster.
|
||||
|
||||
[source, tree]
|
||||
|
@ -3,6 +3,11 @@
|
||||
workflow=$1
|
||||
shift 1
|
||||
|
||||
# Just mind the ordering of the search paths here, the extra `extra-config` is
|
||||
# just the fallback value. As of Nix v2.18, there is a first-come first-serve
|
||||
# precedence so if the user sets the `extra-config` Nix path, it should
|
||||
# override the default.
|
||||
|
||||
# shellcheck disable=SC2068
|
||||
nix-build -A config.system.build.vm -k \
|
||||
--argstr workflow "$workflow" \
|
||||
|
@ -2,13 +2,14 @@
|
||||
, lib
|
||||
, meson
|
||||
, ninja
|
||||
, nix
|
||||
, makeWrapper
|
||||
, inputs ? [ ]
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
pname = "run-workflow-with-vm";
|
||||
version = "2024-03-15";
|
||||
version = "2024-05-10";
|
||||
|
||||
src = ./.;
|
||||
|
||||
@ -22,9 +23,16 @@ stdenv.mkDerivation {
|
||||
mesonFlagsArray+=("-Dinputs=[${lib.concatStringsSep "," inputs}]")
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
wrapProgram $out/bin/${finalAttrs.pname} \
|
||||
--prefix PATH ':' '${lib.makeBinPath [ nix ]}'
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Quickly run workflow modules with a VM.";
|
||||
license = licenses.gpl3Plus;
|
||||
platforms = platforms.linux;
|
||||
mainProgram = finalAttrs.pname;
|
||||
maintainers = with maintainers; [ foo-dogsquared ];
|
||||
};
|
||||
}
|
||||
})
|
||||
|
@ -1,5 +1,5 @@
|
||||
project('run-workflow-with-vm',
|
||||
version: '2024-03-15',
|
||||
version: '2024-05-10',
|
||||
license: 'GPL-3.0-or-later',
|
||||
meson_version: '>=0.54.0',
|
||||
)
|
||||
@ -20,7 +20,7 @@ bindata.set('inputsArgs', inputsArgs)
|
||||
bindata.set('projectname', meson.project_name())
|
||||
configure_file(
|
||||
input: 'app.sh',
|
||||
output: 'run-workflow-with-vm',
|
||||
output: meson.project_name(),
|
||||
configuration: bindata,
|
||||
install_dir: get_option('bindir'),
|
||||
install_mode: 'rwxr-xr-x',
|
||||
|
Loading…
Reference in New Issue
Block a user