File tree Expand file tree Collapse file tree 1 file changed +10
-8
lines changed
hosts/nexus/config/pangolin Expand file tree Collapse file tree 1 file changed +10
-8
lines changed Original file line number Diff line number Diff line change 11{
2+ consts ,
23 config ,
34 lib ,
45 pkgs ,
89let
910 smtp = secrets . users . admin . smtp ;
1011 pangolin = secrets . service . pangolin ;
12+ configPath = "${ consts . DATA_BASE_PATH } /pangolin/config" ;
1113
1214 # Create the configuration files as derivations
1315 pangolinConfigFile = pkgs . writeText "pangolin-config.yml" ''
208210
209211 ## Tmp files and Service to Avoid symlinks
210212 systemd . tmpfiles . rules = [
211- "d /etc/pangolin/config 0755 root root -"
212- "d /etc/pangolin/config /traefik 0755 root root -"
213- "d /etc/pangolin/config /letsencrypt 0755 root root -"
213+ "d ${ configPath } 0755 root root -"
214+ "d ${ configPath } /traefik 0755 root root -"
215+ "d ${ configPath } /letsencrypt 0755 root root -"
214216 ] ;
215217
216218 systemd . services . pangolin-config-sync = {
222224 RemainAfterExit = true ;
223225 } ;
224226 script = ''
225- cp ${ keyFile } /etc/pangolin/config /key
226- chmod 0600 /etc/pangolin/config /key
227- cp ${ pangolinConfigFile } /etc/pangolin/config /config.yml
228- cp ${ traefikConfigFile } /etc/pangolin/config /traefik/traefik_config.yml
229- cp ${ dynamicConfigFile } /etc/pangolin/config /traefik/dynamic_config.yml
227+ cp ${ keyFile } ${ configPath } /key
228+ chmod 0600 ${ configPath } /key
229+ cp ${ pangolinConfigFile } ${ configPath } /config.yml
230+ cp ${ traefikConfigFile } ${ configPath } /traefik/traefik_config.yml
231+ cp ${ dynamicConfigFile } ${ configPath } /traefik/dynamic_config.yml
230232 '' ;
231233 } ;
232234}
You can’t perform that action at this time.
0 commit comments