Skip to content
This repository was archived by the owner on Aug 30, 2024. It is now read-only.

Commit 20324aa

Browse files
authored
Clean up providers create docs (#290)
1 parent b373ac1 commit 20324aa

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

internal/cmd/providers.go

+9-3
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ package cmd
22

33
import (
44
"fmt"
5+
"net/url"
56

67
"cdr.dev/coder-cli/internal/x/xcobra"
78

@@ -64,6 +65,11 @@ coder providers create my-provider --hostname=https://provider.example.com --clu
6465
}
6566

6667
cemanagerURL := client.BaseURL()
68+
ingressHost, err := url.Parse(hostname)
69+
if err != nil {
70+
return xerrors.Errorf("parse hostname: %w", err)
71+
}
72+
6773
version, err := client.APIVersion(ctx)
6874
if err != nil {
6975
return xerrors.Errorf("get application version: %w", err)
@@ -87,15 +93,15 @@ helm upgrade coder-workspace-provider coder/workspace-provider \
8793
--install \
8894
--force \
8995
--set envproxy.token=`+wp.EnvproxyToken+` \
90-
--set ingress.host=`+hostname+` \
96+
--set ingress.host=`+ingressHost.Hostname()+` \
9197
--set envproxy.clusterAddress=`+clusterAddress+` \
92-
--set cemanager.AccessURL=`+cemanagerURL.String()+`
98+
--set cemanager.accessURL=`+cemanagerURL.String()+`
9399
94100
WARNING: The 'envproxy.token' is a secret value that authenticates the workspace provider,
95101
make sure not to share this token or make it public.
96102
97103
Other values can be set on the helm chart to further customize the deployment, see
98-
https:/github.com/cdr/enterprise-helm/blob/workspace-providers-envproxy-only/README.md
104+
https://github.com/cdr/enterprise-helm/blob/workspace-providers-envproxy-only/README.md
99105
`)
100106

101107
return nil

0 commit comments

Comments
 (0)