ensureAbs prepends the WorkDir to the given path if it is not an absolute path.
(path string)
| 30 | |
| 31 | // ensureAbs prepends the WorkDir to the given path if it is not an absolute path. |
| 32 | func ensureAbs(path string) string { |
| 33 | if filepath.IsAbs(path) { |
| 34 | return path |
| 35 | } |
| 36 | return filepath.Join(WorkDir(), path) |
| 37 | } |
| 38 | |
| 39 | // CheckRunUser returns false if configured run user does not match actual user that |
| 40 | // runs the app. The first return value is the actual user name. This check is ignored |