-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: enforce dependencies between fragments
- Loading branch information
Showing
14 changed files
with
94 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,7 +19,7 @@ let | |
MOUNT_DIR="$XDG_RUNTIME_DIR/afs-epita" | ||
klist || kinit -f "[email protected]" | ||
ls "$MOUNT_DIR" || mkdir "$MOUNT_DIR" | ||
ls "$MOUNT_DIR" >/dev/null || mkdir -v "$MOUNT_DIR" | ||
sshfs -o reconnect "[email protected]:$REMOTE_DIR" "$MOUNT_DIR" | ||
''; | ||
}; | ||
|
@@ -28,20 +28,20 @@ in | |
options.local.fragment.epita.enable = lib.mkEnableOption '' | ||
EPITA related | ||
Depends on: SSH | ||
Depends on: | ||
- `ssh` program: Mount AFS script needs SSH | ||
''; | ||
|
||
config = lib.mkIf cfg.enable { | ||
assertions = [ | ||
{ assertion = config.programs.ssh.enable; message = "`epita` fragment depends on `ssh` program"; } | ||
]; | ||
|
||
# Needed for sshfs | ||
programs.ssh = { | ||
# TODO: should depends on ssh module, may conflict later | ||
enable = true; | ||
|
||
matchBlocks."ssh.cri.epita.fr" = { | ||
extraOptions = { | ||
GSSAPIAuthentication = "yes"; | ||
GSSAPIDelegateCredentials = "yes"; | ||
}; | ||
programs.ssh.matchBlocks."ssh.cri.epita.fr" = { | ||
extraOptions = { | ||
GSSAPIAuthentication = "yes"; | ||
GSSAPIDelegateCredentials = "yes"; | ||
}; | ||
}; | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,10 +13,15 @@ in | |
options.local.fragment.git.enable = lib.mkEnableOption '' | ||
Git related | ||
Depends on: Agenix | ||
Depends on: | ||
- `agenix` fragment: Need for GPG key and GitGuardian API key | ||
''; | ||
|
||
config = lib.mkIf cfg.enable { | ||
assertions = [ | ||
{ assertion = config.local.fragment.agenix.enable; message = "`git` fragment depends on `agenix` fragment"; } | ||
]; | ||
|
||
home.sessionVariables = { | ||
# Disable annoying warning message | ||
GIT_DISCOVERY_ACROSS_FILESYSTEM = 0; | ||
|
@@ -27,7 +32,7 @@ in | |
lfs.enable = true; | ||
|
||
userName = "Milo Moisson"; | ||
# TODO: this email should be behind a secret | ||
# TODO: this email should be behind a secret or at least a config | ||
userEmail = "[email protected]"; | ||
|
||
signing = { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters