313db5643f
refactor: rename clanCore -> clan.core
buildbot/nix-build .#checks.x86_64-linux.package-merge-after-ci Build done.
buildbot/nix-build .#checks.x86_64-linux.package-moonlight-sunshine-accept Build done.
buildbot/nix-build .#checks.x86_64-linux.package-pending-reviews Build done.
buildbot/nix-build .#checks.x86_64-linux.package-tea-create-pr Build done.
buildbot/nix-build .#checks.x86_64-linux.package-zerotier-members Build done.
buildbot/nix-build .#checks.x86_64-linux.package-zerotierone Build done.
buildbot/nix-build .#checks.x86_64-linux.package-zt-tcp-relay Build done.
buildbot/nix-build .#checks.x86_64-linux.postgresql Build done.
buildbot/nix-build .#checks.x86_64-linux.package-function-schema Build done.
buildbot/nix-build .#checks.x86_64-linux.secrets Build done.
buildbot/nix-build .#checks.x86_64-linux.nixos-flash-installer Build done.
buildbot/nix-build .#checks.x86_64-linux.nixos-iso-installer Build done.
buildbot/nix-build .#checks.x86_64-linux.template-minimal Build done.
buildbot/nix-build .#checks.x86_64-linux.package-module-schema Build done.
buildbot/nix-build .#checks.x86_64-linux.wayland-proxy-virtwl Build done.
buildbot/nix-build .#checks.x86_64-linux.zt-tcp-relay Build done.
buildbot/nix-build .#checks.x86_64-linux.package-iso-installer Build done.
buildbot/nix-build .#checks.x86_64-linux.syncthing Build done.
buildbot/nix-build .#checks.x86_64-linux.package-docs Build done.
buildbot/nix-build .#checks.x86_64-linux.devShell-clan-app Build done.
buildbot/nix-build .#checks.x86_64-linux.clan-pytest-without-core Build done.
buildbot/nix-build .#checks.x86_64-linux.package-webview-ui Build done.
buildbot/nix-build .#checks.x86_64-linux.package-clan-app Build done.
buildbot/nix-build .#checks.x86_64-linux.package-gui-install-test-ubuntu-22-04 Build done.
buildbot/nix-build .#checks.x86_64-linux.clan-pytest-with-core Build done.
buildbot/nix-build .#checks.x86_64-linux.test-backups Build done.
checks / checks-impure (pull_request) Successful in 2m10s
buildbot/nix-build .#checks.x86_64-linux.flash Build done.
buildbot/nix-build .#checks.x86_64-linux.test-installation Build done.
buildbot/nix-eval Build done.
2024-06-18 18:32:40 +07:00
c926f23c09
clan: add dynamic completions to clan vms inspect
buildbot/nix-build .#checks.x86_64-linux.package-gui-installer-rpm Build done.
buildbot/nix-build .#checks.x86_64-linux.package-impure-checks Build done.
buildbot/nix-build .#checks.x86_64-linux.package-merge-after-ci Build done.
buildbot/nix-build .#checks.x86_64-linux.nixos-test_install_machine Build done.
buildbot/nix-build .#checks.x86_64-linux.package-moonlight-sunshine-accept Build done.
buildbot/nix-build .#checks.x86_64-linux.package-pending-reviews Build done.
buildbot/nix-build .#checks.x86_64-linux.package-tea-create-pr Build done.
buildbot/nix-build .#checks.x86_64-linux.devShell-clan-vm-manager Build done.
buildbot/nix-build .#checks.x86_64-linux.package-zerotier-members Build done.
buildbot/nix-build .#checks.x86_64-linux.package-zt-tcp-relay Build done.
buildbot/nix-build .#checks.x86_64-linux.package-zerotierone Build done.
buildbot/nix-build .#checks.x86_64-linux.clan-pytest-with-core Build done.
buildbot/nix-build .#checks.x86_64-linux.package-function-schema Build done.
buildbot/nix-build .#checks.x86_64-linux.package-deploy-docs Build done.
buildbot/nix-build .#checks.x86_64-linux.nixos-iso-installer Build done.
buildbot/nix-build .#checks.x86_64-linux.package-webview-ui Build done.
buildbot/nix-build .#checks.x86_64-linux.secrets Build done.
buildbot/nix-build .#checks.x86_64-linux.package-module-schema Build done.
buildbot/nix-build .#checks.x86_64-linux.zt-tcp-relay Build done.
buildbot/nix-build .#checks.x86_64-linux.nixos-flash-installer Build done.
buildbot/nix-build .#checks.x86_64-linux.wayland-proxy-virtwl Build done.
buildbot/nix-build .#checks.x86_64-linux.package-iso-installer Build done.
buildbot/nix-build .#checks.x86_64-linux.syncthing Build done.
buildbot/nix-build .#checks.x86_64-linux.package-clan-vm-manager Build done.
buildbot/nix-build .#checks.x86_64-linux.clan-pytest-without-core Build done.
buildbot/nix-build .#checks.x86_64-linux.test-backups Build done.
checks / checks-impure (pull_request) Successful in 2m23s
buildbot/nix-build .#checks.x86_64-linux.flash Build done.
buildbot/nix-build .#checks.x86_64-linux.test-installation Build done.
buildbot/nix-eval Build done.
2024-06-04 15:50:50 +02:00
05ff7bd261
clan: add dynamic completions to clan config
2024-06-04 15:44:39 +02:00
c1e2bc9ea9
make config command read-only
buildbot/nix-build .#checks.x86_64-linux.nixos-test_install_machine Build done.
buildbot/nix-build .#checks.x86_64-linux.lib-jsonschema-nix-unit-tests Build done.
buildbot/nix-build .#checks.x86_64-linux.module-schema Build done.
buildbot/nix-build .#checks.x86_64-linux.package-tea-create-pr Build done.
buildbot/nix-build .#checks.x86_64-linux.package-zerotier-members Build done.
buildbot/nix-build .#checks.x86_64-linux.devShell-clan-vm-manager Build done.
buildbot/nix-build .#checks.x86_64-linux.package-pending-reviews Build done.
buildbot/nix-build .#checks.x86_64-linux.clan-pytest-with-core Build done.
buildbot/nix-build .#checks.x86_64-linux.package-zt-tcp-relay Build done.
buildbot/nix-build .#checks.x86_64-linux.package-docs Build done.
buildbot/nix-build .#checks.x86_64-linux.package-zerotierone Build done.
buildbot/nix-build .#checks.x86_64-linux.package-function-schema Build done.
buildbot/nix-build .#checks.x86_64-linux.package-merge-after-ci Build done.
buildbot/nix-build .#checks.x86_64-linux.package-moonlight-sunshine-accept Build done.
buildbot/nix-build .#checks.x86_64-linux.package-module-schema Build done.
buildbot/nix-build .#checks.x86_64-linux.package-webview-ui Build done.
buildbot/nix-build .#checks.x86_64-linux.secrets Build done.
buildbot/nix-build .#checks.x86_64-linux.nixos-flash-installer Build done.
buildbot/nix-build .#checks.x86_64-linux.nixos-iso-installer Build done.
buildbot/nix-build .#checks.x86_64-linux.package-clan-vm-manager Build done.
buildbot/nix-build .#checks.x86_64-linux.wayland-proxy-virtwl Build done.
buildbot/nix-build .#checks.x86_64-linux.package-iso-installer Build done.
buildbot/nix-build .#checks.x86_64-linux.zt-tcp-relay Build done.
buildbot/nix-build .#checks.x86_64-linux.syncthing Build done.
buildbot/nix-build .#checks.x86_64-linux.clan-pytest-without-core Build done.
buildbot/nix-build .#checks.x86_64-linux.test-backups Build done.
checks / checks-impure (pull_request) Successful in 2m20s
buildbot/nix-build .#checks.x86_64-linux.flash Build done.
buildbot/nix-build .#checks.x86_64-linux.test-installation Build done.
buildbot/nix-eval Build done.
2024-05-29 13:17:55 +02:00
0133ccd5f7
Fixed missing log.BOTH and error_msg at prev refactors
2024-01-11 21:11:49 +01:00
2ae439ec52
cmd.py refactor part 4
2024-01-11 21:11:49 +01:00
f6b6229f78
schema: set also clanName
...
checks-impure / test (pull_request) Successful in 1m18s
checks / test (pull_request) Failing after 2m49s
this is usually set by buildClan
2024-01-11 17:41:41 +01:00
b36d0be524
cmd.py part 3 refactor
checks-impure / test (pull_request) Failing after 1m25s
checks / test (pull_request) Failing after 3m8s
2024-01-10 18:39:19 +01:00
ba05589af2
Refactor subprocess to cmd.py part 2
checks-impure / test (pull_request) Failing after 16s
checks / test (pull_request) Failing after 40s
2024-01-10 12:11:29 +01:00
4fd84d1c48
disallow variable shadowing
2023-11-30 14:31:37 +01:00
f1b223d0a1
modernisation for python 3.11
2023-11-29 13:29:45 +00:00
26e3e3872c
enable more linting
2023-11-29 13:29:45 +00:00
8759e5a049
drop dependency on fastapi in the cli
checks-impure / test (pull_request) Successful in 1m35s
checks / test (pull_request) Successful in 2m57s
2023-11-21 15:09:18 +01:00
1ea13646ea
clan_cli: flake_name -> flake_dir
checks / test (pull_request) Failing after 1m7s
checks-impure / test (pull_request) Successful in 1m31s
2023-11-15 16:23:28 +01:00
6a52c5f15b
api/machines: allow config verification on imaginary machines
...
checks-impure / test (pull_request) Successful in 1m37s
checks / test (pull_request) Successful in 2m39s
Machines do not need to exist in order to verify their configuration.
This allows verifying a config before creating an actual machine with it.
2023-11-13 21:24:05 +07:00
55a1df7868
api/machines: verify config by evaluating the .vm output
...
checks-impure / test (pull_request) Successful in 1m33s
checks / test (pull_request) Successful in 2m34s
This fixes the problem where fileSystems were missing, or boot.loader was not set.
SInce we want VMs anyways for now, this strategy aligns well
2023-11-13 20:50:11 +07:00
1652b5c27b
api/machines: init put_machine replacing create_machine and set_machine_config
...
checks-impure / test (pull_request) Successful in 1m36s
checks / test (pull_request) Successful in 1m59s
This allows creating and configuring a machine in one single step.
2023-11-13 20:25:52 +07:00
39607a0925
api/schema: return list of missing modules
checks-impure / test (pull_request) Successful in 1m58s
checks / test (pull_request) Successful in 2m48s
2023-11-10 15:07:15 +07:00
97ea9312ac
api/schema: don't crash on eval error
checks-impure / test (pull_request) Successful in 1m32s
checks / test (pull_request) Successful in 2m25s
2023-11-10 14:27:03 +07:00
2a6e329e40
api/schema: get schema without having a machine
...
checks-impure / test (pull_request) Successful in 1m32s
checks / test (pull_request) Successful in 2m22s
Also done:
- add @pytest.mark.with_core indicating that a test depends on clan-core and cannot be cached
- separate unit tests into two derivations, ones that can be cached and ones that cannot.
- fix frontend typescript code
2023-11-09 15:30:25 +07:00
00ef406713
Updated to main branch. Removed cluttering asyncio and httpx log messages
2023-10-27 23:36:45 +02:00
f9b1a8fa89
Removing find_git_repo
2023-10-27 19:26:03 +02:00
efd201c7c5
nix fmt
2023-10-27 19:26:03 +02:00
d1c35301e3
Added repro_env_break debugging command. This spawn a terminal inside the temp home folder with the same environment as the python test
2023-10-27 19:20:17 +02:00
59393bb35e
Working test_create_flake
2023-10-27 19:20:17 +02:00
d02acbe04b
nix fmt
2023-10-27 19:19:45 +02:00
8cc1c2c4bd
Fixed cyclic dependencie AND swapped pytest-parallel for pytest-xdist to fix deadlock in tests
2023-10-27 19:18:45 +02:00
2ca54afe7f
Added new type FlakeName
2023-10-27 19:18:45 +02:00
32e60f5adc
Added flake_name:str argument everywhere, nix fmt doesn't complain anymore
2023-10-27 19:15:40 +02:00
fdcd7ad1d9
Updated to main
2023-10-27 19:15:11 +02:00
0e5c7d2d13
api/machines: split off config validation into separate endpoint
...
checks-impure / test (pull_request) Successful in 1m1s
checks / test (pull_request) Successful in 1m36s
- This speeds up PUT /machines{name}/config as it doesn't do the expensive check anymore
- instead use PUT /machines/{name}/verify which allows a dry-run evaluation of a config which is passed without writing it to disk
2023-10-25 17:48:37 +01:00
bf176ad277
api/machines: allow importing extra modules
...
checks-impure / test (pull_request) Successful in 36s
checks / test (pull_request) Successful in 2m6s
- add top-level option `clanImports` to clanCore
- clanImports can be set and checked as any other option
- buildClan resolves the clanImports from the settings.json before calling evalModules to prevent infinite recursions
- new endpoint PUT machines/{name}/schema to allow getting the schema for a specific list of imports
- to retrieve the currently imported modules, cimply do a GET or PU on machines/{name}/config which will return `clanImports` as part of the config
Still missing: get list of available modules
2023-10-25 16:36:30 +01:00
588bde069f
PUT api/machines/{name}/config: ensure only valid config is ever written
...
checks-impure / test (pull_request) Successful in 1m0s
checks / test (pull_request) Successful in 2m24s
- add CLAN_MACHINE_SETTINGS_FILE variable to temporarily override the machine settings file
- do a dry-run evaluation first with the new config before persisting it.
2023-10-24 18:40:48 +01:00
a539fb6dc6
machines: add endpoint machines/{name}/ verify
checks-impure / test (pull_request) Successful in 58s
checks / test (pull_request) Successful in 8m48s
2023-10-24 16:31:37 +01:00
cd940abc4e
clan config: refactor - reorder functions
checks-impure / test (pull_request) Successful in 57s
checks / test (pull_request) Successful in 7m21s
2023-10-24 15:27:19 +01:00
2f73e6b472
drop requirement for importing qemu-vm.nix
checks-impure / test (pull_request) Successful in 13s
checks / test (pull_request) Successful in 22s
2023-09-27 14:54:01 +02:00
677494811b
Merge pull request 'clan config: print command in more instances' ( #342 ) from Mic92-docs into main
checks-impure / test (push) Successful in 8s
checks / test (push) Successful in 1m17s
assets1 / test (push) Successful in 6s
2023-09-26 12:13:09 +00:00
f85fdf678d
clan config: print command in more instances
checks / test (pull_request) Successful in 23s
checks-impure / test (pull_request) Successful in 9s
2023-09-26 14:10:52 +02:00
da1927581d
Merge pull request 'unpin nix-fast-build' ( #341 ) from Mic92-docs into main
checks-impure / test (push) Successful in 8s
checks / test (push) Successful in 1m18s
assets1 / test (push) Successful in 6s
2023-09-26 12:02:05 +00:00
29a48725ef
clan config: print command on error
checks / test (pull_request) Successful in 1m18s
checks-impure / test (pull_request) Successful in 10s
2023-09-26 14:00:20 +02:00
3783359f08
clan config: support new types nullOr and passwdEntry
checks-impure / test (pull_request) Successful in 8s
checks / test (pull_request) Successful in 23s
2023-09-24 14:24:48 +01:00
ec70b34470
clan config: match dynamic options containing <name>
checks-impure / test (pull_request) Successful in 8s
checks / test (pull_request) Successful in 23s
2023-09-24 13:04:37 +01:00
ea829a76cd
config: git commit synched file
checks-impure / test (pull_request) Successful in 9s
checks / test (pull_request) Successful in 26s
2023-09-22 16:55:51 +02:00
fa9e8d757d
add show-trace option that is disabled by default
checks-impure / test (pull_request) Successful in 11s
checks / test (pull_request) Successful in 1m16s
2023-09-22 16:07:39 +02:00
e3b2424d9d
make git optional again
2023-09-22 16:07:39 +02:00
d8bde6ec8e
fix reading options
checks-impure / test (pull_request) Successful in 12s
checks / test (pull_request) Successful in 1m2s
2023-09-22 14:54:44 +02:00
660dafd412
config: read nixos option correctly
checks-impure / test (pull_request) Successful in 9s
checks / test (pull_request) Successful in 20s
2023-09-22 14:38:23 +02:00
51e8da2a74
config: get rid of impure eval
checks-impure / test (pull_request) Successful in 8s
checks / test (pull_request) Successful in 23s
2023-09-22 14:32:38 +02:00
6a359c0a2f
clan-cli: add git.commit_file() to auto commit files if inside a git
...
checks-impure / test (pull_request) Successful in 10s
checks / test (pull_request) Successful in 34s
- commit only if inside a git repo
- commit only the specified file and nothing else
- auto-generate commit message if not specified
2023-09-21 14:07:54 +02:00
c11f73c4d0
clan config: fix settings file location
checks-impure / test (pull_request) Successful in 12s
checks / test (pull_request) Successful in 1m10s
2023-09-19 15:12:29 +02:00