InstallScript installs a script on a Proxmox node interactively.
(scriptPath string)
| 560 | |
| 561 | // InstallScript installs a script on a Proxmox node interactively. |
| 562 | func validateScriptPath(scriptPath string) error { |
| 563 | for _, c := range scriptPath { |
| 564 | if !((c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || (c >= '0' && c <= '9') || c == '/' || c == '.' || c == '_' || c == '-') { |
| 565 | return fmt.Errorf("invalid script path character: %c", c) |
| 566 | } |
| 567 | } |
| 568 | return nil |
| 569 | } |
| 570 | |
| 571 | // ParseEnvOverride parses and validates a KEY=VALUE Community Scripts override. |
| 572 | func ParseEnvOverride(raw string) (EnvOverride, error) { |
no outgoing calls
no test coverage detected