SSHAddrstring`kong:"flag,name='ssh-listen-addr',env='HGK_SSH_LISTEN_ADDR',short='l',help='what address to listen on',default=':22222'"`
SSHHostKeysPathstring`kong:"flag,name='ssh-host-keys-path',env='HGK_SSH_HOST_KEYS_PATH',short='H',help='the path where host keys are kept',default='host-keys'"`
HTTPAddrstring`kong:"flag,name='http-listen-addr',env='HGK_HTTP_LISTEN_ADDR',help='what address the http server listens on',default=':8080'"`
DisableSSHbool`kong:"flag,name='disable-ssh',env='HGK_DISABLE_SSH',help='disable the SSH server',default='false'"`
DisableHGWebbool`kong:"flag,name='disable-hgweb',env='HGK_DISABLE_HGWEB',help='disable the HGWEB cgi server',default='false'"`
ExternalHostnamestring`kong:"flag,name='external-hostname',env='HGK_EXTERNAL_HOSTNAME',help='The external hostname of the hgkeeper instance. This is used to integrate with other ssh servers.'"`
ExternalPortstring`kong:"flag,name='external-port',env='HGK_EXTERNAL_PORT',help='The external port of the hgkeeper instance. This is used to itegrate with other ssh servers.',default='22222'"`
}
func(c*Command)Run(g*globals.Globals)error{
ifc.DisableHGWeb&&c.DisableSSH{
returnfmt.Errorf("both HGWeb and SSH servers have been disabled")