Skip to content

Commit

Permalink
Add modesetting
Browse files Browse the repository at this point in the history
  • Loading branch information
pinpox committed May 11, 2024
1 parent ecb5dbd commit 2b279cd
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -65,10 +65,14 @@
''
${secretConfig.cmd} | {{.REMOTE_COMMAND}} {{.REMOTE_SSH_OPTS}} {{.REMOTE_USER}}@{{.REMOTE_HOST}} "umask 077; cat > ${pkgs.lib.escapeShellArg secretConfig.path}"
''
# # Set group and owner
# Set group and owner
''
{{.REMOTE_COMMAND}} {{.REMOTE_SSH_OPTS}} {{.REMOTE_USER}}@{{.REMOTE_HOST}} "chown ${secretConfig.owner}:${secretConfig.group-name} ${pkgs.lib.escapeShellArg secretConfig.path}"
''
# Set mode
''
{{.REMOTE_COMMAND}} {{.REMOTE_SSH_OPTS}} {{.REMOTE_USER}}@{{.REMOTE_HOST}} "chmod ${secretConfig.mode} ${pkgs.lib.escapeShellArg secretConfig.path}"
''
])
userconfig.lollypops.secrets.files))

Expand Down Expand Up @@ -149,6 +153,13 @@
"${optionalString useSudo "{{.REMOTE_SUDO_COMMAND}} {{.REMOTE_SUDO_OPTS}}"} \
chown ${x.owner}:${x.group-name} ${path}"
''

# Set group and owner
''
{{.REMOTE_COMMAND}} {{.REMOTE_SSH_OPTS}} {{.REMOTE_USER}}@{{.REMOTE_HOST}} \
"${optionalString useSudo "{{.REMOTE_SUDO_COMMAND}} {{.REMOTE_SUDO_OPTS}}"} \
chmod ${x.mode} ${path}"
''
])
(builtins.attrValues config.lollypops.secrets.files));
in
Expand Down

0 comments on commit 2b279cd

Please sign in to comment.