versionFlag := flags.Bool("version", false, "Write version information to stdout and exit 0")
flags.StringVar(&initcmd.ClusterID, "cluster-id", "", "cluster `id`, like x1234 for a dev cluster")
flags.StringVar(&initcmd.Domain, "domain", hostname, "cluster public DNS `name`, like x1234.arvadosapi.com")
- err = flags.Parse(args)
- if err == flag.ErrHelp {
- err = nil
- return 0
- } else if err != nil {
- return 2
+ if ok, code := cmd.ParseFlags(flags, prog, args, "", stderr); !ok {
+ return code
} else if *versionFlag {
return cmd.Version.RunCommand(prog, args, stdin, stdout, stderr)
- } else if len(flags.Args()) > 0 {
- err = fmt.Errorf("unrecognized command line arguments: %v", flags.Args())
- return 2
} else if !regexp.MustCompile(`^[a-z][a-z0-9]{4}`).MatchString(initcmd.ClusterID) {
err = fmt.Errorf("cluster ID %q is invalid; must be an ASCII letter followed by 4 alphanumerics (try -help)", initcmd.ClusterID)
return 1
InternalURLs:
"http://0.0.0.0:8001/": {}
ExternalURL: {{printf "%q" ( print "https://workbench." .Domain "/" ) }}
- Workbench2:
- InternalURLs:
- "http://0.0.0.0:8002/": {}
- ExternalURL: {{printf "%q" ( print "https://workbench2." .Domain "/" ) }}
+ #Workbench2:
+ # InternalURLs:
+ # "http://0.0.0.0:8002/": {}
+ # ExternalURL: {{printf "%q" ( print "https://workbench2." .Domain "/" ) }}
Health:
InternalURLs:
"http://0.0.0.0:9007/": {}
- API:
- RailsSessionSecretToken: {{printf "%q" ( .RandomHex 50 )}}
Collections:
BlobSigningKey: {{printf "%q" ( .RandomHex 50 )}}
Containers:
user: arvados
password: {{printf "%q" .PostgreSQLPassword}}
SystemRootToken: {{printf "%q" ( .RandomHex 50 )}}
+ TLS:
+ Insecure: true
Volumes:
{{.ClusterID}}-nyw5e-000000000000000:
Driver: Directory
DriverParameters:
Root: /var/lib/arvados/keep
Replication: 2
+ Workbench:
+ SecretKeyBase: {{printf "%q" ( .RandomHex 50 )}}
`)
if err != nil {
return 1