Skip to content

Commit 995c64e

Browse files
monyarmMartinNikov
authored andcommitted
docs(mcl): command usage in README
1 parent 0ce62c5 commit 995c64e

File tree

1 file changed

+84
-0
lines changed

1 file changed

+84
-0
lines changed

README.md

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,87 @@ jobs:
1212
uses: metacraft-labs/nixos-modules/.github/workflows/ci.yml@main
1313
secrets: inherit
1414
```
15+
16+
## MCL command
17+
18+
The mcl tool contained in this repository has a number of commands which can be given to it as a commandline argument. They are:
19+
20+
### ci_matrix
21+
22+
Evaluates each package, and compares it to it's last cached version, creating a table listing which packages are cached, which aren't, and which failed.
23+
This command is not meant to be run manually, but rather to be ran by the CI.
24+
25+
ENV Variables:
26+
- IS_INITIAL: `true` or `false`
27+
- CACHIX_CACHE: Which cachix cache to search
28+
- CACHIX_AUTH_TOKEN: The auth token for the cache
29+
- FLAKE_PRE: Flake path prefix
30+
- FLAKE_POST: Flake path postfix
31+
32+
Usage: Use `mcl ci` instead
33+
34+
### ci
35+
36+
Evaluates each package, and compares it to it's last cached version, creating a table listing which packages are cached, which aren't, and which failed.
37+
38+
ENV Variables:
39+
- IS_INITIAL: `true` or `false`
40+
- CACHIX_CACHE: Which cachix cache to search
41+
- CACHIX_AUTH_TOKEN: The auth token for the cache
42+
- FLAKE_PRE: Flake path prefix
43+
- FLAKE_POST: Flake path postfix
44+
45+
Usage: `mcl ci`
46+
47+
### deploy_spec
48+
49+
Deploys machine specs to cachix.
50+
51+
Usage: `mcl deploy_spec`
52+
53+
### get_fstab
54+
55+
ENV Variables:
56+
- IS_INITIAL: `true` or `false`
57+
- CACHIX_CACHE: Which cachix cache to search
58+
- CACHIX_AUTH_TOKEN: The auth token for the cache
59+
- [Optional] CACHIX_STORE_URL: URL for the cachix store
60+
- [Optional] CACHIX_DEPLOY_WORKSPACE: Workspace for cachix deploy (defaults to CACHIX_CACHE if not set)
61+
- MACHINE_NAME: Which machine to serach
62+
- DEPLOYMENT_ID: Id of cachix deployment
63+
64+
Usage: `mcl get_fstab`
65+
66+
### host_info
67+
68+
Returns system information, software (OS, Bios) and hardware (CPU, GPU, Ram, MB, Disks) as json.
69+
70+
Usage: `mcl host_info`
71+
72+
### machine_create
73+
74+
Create a starting nix configuration for target machine.
75+
76+
ENV Variables:
77+
- SSH_PATH: SSH path of target machine
78+
79+
The remaining ENV variables are optional, and if missing will be prompted at runtime.
80+
- CREATE_USER: bool
81+
- USER_NAME: string
82+
- MACHINE_NAME: string
83+
- DESCRIPTION: string
84+
- IS_NORMAL_USER: bool
85+
- EXTRA_GROUPS: comma-delimited list of additional groups to add to the created user
86+
- MACHINE_TYPE: enum (desktop, server, container)
87+
- DISKS: comma-delimited list of device names (as per /dev) to add to the nix configuration
88+
89+
Usage: `mcl machine_create`
90+
91+
### shard_matrix
92+
93+
Splits the list of packages under `checks` into n number of shards. Requires manual configuration using modules/shard-split. See this repo and `nix-blockchain-development`
94+
95+
ENV Variables:
96+
- [Optional] GITHUB_OUTPUT: If set, exports results to GITHUB_INPUT env variable
97+
98+
Usage: `mcl shard_matrix`

0 commit comments

Comments
 (0)