mirror of
https://github.com/coder/coder.git
synced 2025-07-18 14:17:22 +00:00
chore: Remove url and wildcard url from moon create (#7224)
* chore: Remove url and wildcard url from moon create
This commit is contained in:
@ -55,13 +55,11 @@ func (r *RootCmd) deleteProxy() *clibase.Cmd {
|
||||
|
||||
func (r *RootCmd) createProxy() *clibase.Cmd {
|
||||
var (
|
||||
proxyName string
|
||||
displayName string
|
||||
proxyIcon string
|
||||
proxyURL string
|
||||
proxyWildcardHostname string
|
||||
onlyToken bool
|
||||
formatter = cliui.NewOutputFormatter(
|
||||
proxyName string
|
||||
displayName string
|
||||
proxyIcon string
|
||||
onlyToken bool
|
||||
formatter = cliui.NewOutputFormatter(
|
||||
// Text formatter should be human readable.
|
||||
cliui.ChangeFormatterData(cliui.TextFormat(), func(data any) (any, error) {
|
||||
response, ok := data.(codersdk.CreateWorkspaceProxyResponse)
|
||||
@ -94,11 +92,9 @@ func (r *RootCmd) createProxy() *clibase.Cmd {
|
||||
Handler: func(inv *clibase.Invocation) error {
|
||||
ctx := inv.Context()
|
||||
resp, err := client.CreateWorkspaceProxy(ctx, codersdk.CreateWorkspaceProxyRequest{
|
||||
Name: proxyName,
|
||||
DisplayName: displayName,
|
||||
Icon: proxyIcon,
|
||||
URL: proxyURL,
|
||||
WildcardHostname: proxyWildcardHostname,
|
||||
Name: proxyName,
|
||||
DisplayName: displayName,
|
||||
Icon: proxyIcon,
|
||||
})
|
||||
if err != nil {
|
||||
return xerrors.Errorf("create workspace proxy: %w", err)
|
||||
@ -136,16 +132,6 @@ func (r *RootCmd) createProxy() *clibase.Cmd {
|
||||
Description: "Display icon of the proxy.",
|
||||
Value: clibase.StringOf(&proxyIcon),
|
||||
},
|
||||
clibase.Option{
|
||||
Flag: "access-url",
|
||||
Description: "Access URL of the proxy.",
|
||||
Value: clibase.StringOf(&proxyURL),
|
||||
},
|
||||
clibase.Option{
|
||||
Flag: "wildcard-access-url",
|
||||
Description: "(Optional) Access url of the proxy for subdomain based apps.",
|
||||
Value: clibase.StringOf(&proxyWildcardHostname),
|
||||
},
|
||||
clibase.Option{
|
||||
Flag: "only-token",
|
||||
Description: "Only print the token. This is useful for scripting.",
|
||||
|
Reference in New Issue
Block a user