mirror of
https://github.com/empayre/fleet.git
synced 2024-11-06 08:55:24 +00:00
Shebang should be on the first line of script (#5747)
* Shebang should be on the first line of script * Set 644 file mode for SystemD unit file
This commit is contained in:
parent
78b1a60a0d
commit
bc9f2b1b16
@ -5,6 +5,8 @@ const (
|
||||
DefaultDirMode = 0o755
|
||||
// DefaultFileMode is the default file mode to apply to created files.
|
||||
DefaultFileMode = 0o600
|
||||
// DefaultSystemdUnitMode is the required file mode to systemd unit files.
|
||||
DefaultSystemdUnitMode = 0o644
|
||||
// DesktopAppExecName is the name of Fleet's Desktop executable.
|
||||
//
|
||||
// We use fleet-desktop as name to properly identify the process when listing
|
||||
|
@ -228,7 +228,7 @@ CPUQuota=20%
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
`),
|
||||
constant.DefaultFileMode,
|
||||
constant.DefaultSystemdUnitMode,
|
||||
); err != nil {
|
||||
return fmt.Errorf("write file: %w", err)
|
||||
}
|
||||
@ -275,8 +275,7 @@ func writeEnvFile(opt Options, rootPath string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
var postInstallTemplate = template.Must(template.New("postinstall").Parse(`
|
||||
#!/bin/sh
|
||||
var postInstallTemplate = template.Must(template.New("postinstall").Parse(`#!/bin/sh
|
||||
|
||||
# Exit on error
|
||||
set -e
|
||||
|
Loading…
Reference in New Issue
Block a user