diff --git a/cmd/pro/list.go b/cmd/pro/list.go index 3d94c6f34c..962b7a027f 100644 --- a/cmd/pro/list.go +++ b/cmd/pro/list.go @@ -34,7 +34,7 @@ func NewListCmd(flags *proflags.GlobalFlags) *cobra.Command { listCmd := &cobra.Command{ Use: "list", Aliases: []string{"ls"}, - Short: "List available Devsy Pro instances", + Short: "List available Devsy Platform instances", Args: cobra.NoArgs, Annotations: telemetry.SkipInUIAnnotation(), RunE: func(cobraCmd *cobra.Command, args []string) error { diff --git a/cmd/pro/login.go b/cmd/pro/login.go index cc750d827e..4436947efc 100644 --- a/cmd/pro/login.go +++ b/cmd/pro/login.go @@ -47,7 +47,7 @@ func NewLoginCmd(flags *proflags.GlobalFlags) *cobra.Command { } loginCmd := &cobra.Command{ Use: "login HOST", - Short: "Log into a Devsy Pro instance", + Short: "Log into a Devsy Platform instance", Args: cobra.ExactArgs(1), RunE: func(cobraCmd *cobra.Command, args []string) error { return cmd.Run(cobraCmd.Context(), args[0]) @@ -66,7 +66,7 @@ func NewLoginCmd(flags *proflags.GlobalFlags) *cobra.Command { &cmd.Login, names.Login, true, - "If enabled will automatically try to log into Devsy Pro", + "If enabled will automatically try to log into Devsy Platform", ), cliflags.Bool( &cmd.Use, @@ -78,7 +78,7 @@ func NewLoginCmd(flags *proflags.GlobalFlags) *cobra.Command { &cmd.Provider, names.Provider, "", - "Optional name how the Devsy Pro provider will be named", + "Optional name how the Devsy Platform provider will be named", ), cliflags.String( &cmd.Version, @@ -176,7 +176,7 @@ func (cmd *LoginCmd) prepareProvider(ctx context.Context, fullURL string) (*conf func (cmd *LoginCmd) normalizeURL(fullURL string) (string, error) { if strings.HasPrefix(fullURL, "http://") { - return "", fmt.Errorf("http is not supported for Devsy Pro, use https:// instead") + return "", fmt.Errorf("http is not supported for Devsy Platform, use https:// instead") } if !strings.HasPrefix(fullURL, "https://") { return "https://" + fullURL, nil @@ -346,7 +346,7 @@ func (cmd *LoginCmd) loginAndConfigure( if err != nil { return err } - log.Infof("logged into Devsy Pro instance: url=%s", fullURL) + log.Infof("logged into Devsy Platform instance: url=%s", fullURL) } if cmd.Use { @@ -380,7 +380,7 @@ func (cmd *LoginCmd) loginAndConfigure( } } - log.Info("configured Devsy Pro") + log.Info("configured Devsy Platform") return nil } @@ -396,7 +396,7 @@ func (cmd *LoginCmd) addDevsyProvider( } // add the provider - log.Infof("Add Devsy Pro provider") + log.Infof("Add Devsy Platform provider") // is development? if cmd.ProviderSource == config.RepoSlug+"@v0.0.0" { diff --git a/cmd/pro/logout.go b/cmd/pro/logout.go index cf0e4c059c..39a9dddbd0 100644 --- a/cmd/pro/logout.go +++ b/cmd/pro/logout.go @@ -36,7 +36,7 @@ func NewLogoutCmd(flags *proflags.GlobalFlags) *cobra.Command { } logoutCmd := &cobra.Command{ Use: "logout", - Short: "Log out of a Devsy Pro instance", + Short: "Log out of a Devsy Platform instance", RunE: func(cobraCmd *cobra.Command, args []string) error { return cmd.Run(cobraCmd.Context(), args) }, diff --git a/cmd/pro/pro.go b/cmd/pro/pro.go index d277351152..bd0b3dc4ac 100644 --- a/cmd/pro/pro.go +++ b/cmd/pro/pro.go @@ -18,7 +18,7 @@ func NewPlatformCmd(flags *flags.GlobalFlags) *cobra.Command { globalFlags := &proflags.GlobalFlags{GlobalFlags: flags} platformCmd := &cobra.Command{ Use: "pro", - Short: "Devsy Pro commands", + Short: "Devsy Platform commands", SilenceUsage: true, SilenceErrors: true, Args: cobra.NoArgs, diff --git a/cmd/pro/start.go b/cmd/pro/start.go index 58b12258a3..f4cd95d10a 100644 --- a/cmd/pro/start.go +++ b/cmd/pro/start.go @@ -94,7 +94,7 @@ func NewStartCmd(flags *proflags.GlobalFlags) *cobra.Command { } startCmd := &cobra.Command{ Use: "start", - Short: "Start a Devsy Pro instance", + Short: "Start a Devsy Platform instance", RunE: func(cobraCmd *cobra.Command, args []string) error { return cmd.Run(cobraCmd.Context()) }, @@ -131,7 +131,7 @@ func (cmd *StartCmd) Run(ctx context.Context) error { } // Install Devsy - log.Info("Welcome to Devsy Pro!") + log.Info("Welcome to Devsy Platform!") log.Info("This installer will help you to get started.") // make sure we are ready for installing @@ -331,7 +331,7 @@ func (cmd *StartCmd) upgrade(ctx context.Context) error { if !cmd.Reset { return errors.New( err.Error() + fmt.Sprintf( - "\n\nIf want to purge and reinstall Devsy Pro, run: %s\n", + "\n\nIf want to purge and reinstall Devsy Platform, run: %s\n", greenBold("devsy pro start --reset"), ), ) @@ -451,7 +451,7 @@ func (cmd *StartCmd) successRemote(ctx context.Context, host string) error { return err } - log.Info("Devsy Pro is reachable at https://" + host) + log.Info("Devsy Platform is reachable at https://" + host) cmd.printRemoteSuccessMessage(host) return nil @@ -481,9 +481,9 @@ Follow this guide to add a valid certificate: %s ################################################################# -Devsy Pro was successfully installed and can now be reached at: %s +Devsy Platform was successfully installed and can now be reached at: %s -Thanks for using Devsy Pro! +Thanks for using Devsy Platform! `, greenBold(url), greenBold("devsy pro login "+url), @@ -509,12 +509,12 @@ EXTERNAL-IP may be 'pending' for a while until your cloud provider has created a ######################################################################################################### -The command will wait until Devsy Pro is reachable under the host. +The command will wait until Devsy Platform is reachable under the host. `) log.Info( - "Waiting for you to configure DNS, so Devsy Pro can be reached on https://" + host, + "Waiting for you to configure DNS, so Devsy Platform can be reached on https://" + host, ) } @@ -559,9 +559,9 @@ Login via CLI: %s ################################################################# -Devsy Pro was successfully installed. +Devsy Platform was successfully installed. -Thanks for using Devsy Pro! +Thanks for using Devsy Platform! `, greenBold(url), greenBold("devsy pro login"+" --insecure "+url)) blockChan := make(chan bool) <-blockChan @@ -844,7 +844,7 @@ func (cmd *StartCmd) ensureHostAndIngress(ctx context.Context) error { func (cmd *StartCmd) waitForDeployment(ctx context.Context) (*corev1.Pod, error) { // wait for devsy pod to start - log.Info("waiting for Devsy Pro pod to be running") + log.Info("waiting for Devsy Platform pod to be running") devsyPod, err := platform.WaitForPodReady(ctx, cmd.KubeClient, cmd.Namespace) log.Infof("release Pod started") if err != nil { @@ -895,7 +895,7 @@ func (cmd *StartCmd) pingDevsyRouter(ctx context.Context, devsyPod *corev1.Pod) }, }, } - log.Infof("Waiting until Devsy Pro is reachable at https://%s", devsyRouterDomain) + log.Infof("Waiting until Devsy Platform is reachable at https://%s", devsyRouterDomain) err = wait.PollUntilContextTimeout( ctx, time.Second*3, @@ -954,9 +954,9 @@ Login via CLI: %s ################################################################# -Devsy Pro was successfully installed and can now be reached at: %s +Devsy Platform was successfully installed and can now be reached at: %s -Thanks for using Devsy Pro! +Thanks for using Devsy Platform! `, greenBold(url), greenBold("devsy pro login"+" "+url), @@ -1146,7 +1146,7 @@ func enterHostNameQuestion() (string, error) { return log.QuestionDefault(&survey.QuestionOptions{ Question: fmt.Sprintf( "Enter a hostname for your %s instance (e.g. loft.my-domain.tld): \n ", - config.ProductNamePro, + config.ProductNamePlatform, ), ValidationFunc: func(answer string) error { u, err := netUrl.Parse("https://" + answer) @@ -1500,7 +1500,7 @@ func upgradeRelease( return fmt.Errorf("error during helm command: %s (%w)", string(output), err) } - log.Infof("Devsy Pro has been deployed to your cluster!") + log.Infof("Devsy Platform has been deployed to your cluster!") return nil } diff --git a/cmd/pro/start_docker.go b/cmd/pro/start_docker.go index 285f59ad95..1cf4e74e4e 100644 --- a/cmd/pro/start_docker.go +++ b/cmd/pro/start_docker.go @@ -25,8 +25,8 @@ import ( var ( ErrMissingContainer = errors.New("missing container") - //nolint:staticcheck // ST1005: "Devsy Pro" is a proper noun - ErrPlatformNotReachable = errors.New("Devsy Pro is not reachable") + //nolint:staticcheck // ST1005: "Devsy Platform" is a proper noun + ErrPlatformNotReachable = errors.New("Devsy Platform is not reachable") ) type ContainerDetails struct { @@ -59,7 +59,7 @@ type ContainerDetailsState struct { } func (cmd *StartCmd) startDocker(ctx context.Context) error { - log.Infof("Starting Devsy Pro in Docker") + log.Infof("Starting Devsy Platform in Docker") name := config.PlatformReleaseName // prepare installation @@ -92,7 +92,7 @@ func (cmd *StartCmd) startDocker(ctx context.Context) error { } // Install Devsy - log.Info("Welcome to Devsy Pro!") + log.Info("Welcome to Devsy Platform!") log.Info("This installer will help you get started.") // make sure we are ready for installing @@ -138,7 +138,7 @@ func (cmd *StartCmd) successDocker(ctx context.Context, containerID string) erro } // wait for domain to become reachable - log.Infof("Wait for Devsy Pro to become available at %s", host) + log.Infof("Wait for Devsy Platform to become available at %s", host) err = wait.PollUntilContextTimeout( ctx, time.Second, @@ -162,7 +162,7 @@ func (cmd *StartCmd) successDocker(ctx context.Context, containerID string) erro }, ) if err != nil { - return fmt.Errorf("error waiting for Devsy Pro: %w", err) + return fmt.Errorf("error waiting for Devsy Platform: %w", err) } // print success message @@ -184,9 +184,9 @@ Login via CLI: %s ################################################################# -Devsy Pro was successfully installed and can now be reached at: %s +Devsy Platform was successfully installed and can now be reached at: %s -Thanks for using Devsy Pro! +Thanks for using Devsy Platform! `, greenBold(url), greenBold("devsy pro login"+" "+url), @@ -195,7 +195,7 @@ Thanks for using Devsy Pro! } func (cmd *StartCmd) waitForDevsyDocker(ctx context.Context, containerID string) (string, error) { - log.Info("Wait for Devsy Pro to become available") + log.Info("Wait for Devsy Platform to become available") // check for local port containerDetails, err := cmd.inspectContainer(ctx, containerID) @@ -211,7 +211,7 @@ func (cmd *StartCmd) waitForDevsyDocker(ctx context.Context, containerID string) return "", fmt.Errorf( "%w: %s", ErrPlatformNotReachable, - "cannot connect to Devsy Pro as it has no exposed port and --no-tunnel is enabled", + "cannot connect to Devsy Platform as it has no exposed port and --no-tunnel is enabled", ) } @@ -316,7 +316,7 @@ func (cmd *StartCmd) runInDocker(ctx context.Context, name string) (string, erro args = append(args, "ghcr.io/devsy-org/devsy-pro:latest") } - log.Infof("Start Devsy Pro via 'docker %s'", strings.Join(args, " ")) + log.Infof("Start Devsy Platform via 'docker %s'", strings.Join(args, " ")) runCmd := cmd.buildDockerCmd(ctx, args...) runCmd.Stdout = os.Stdout runCmd.Stderr = os.Stderr diff --git a/cmd/pro/start_flags.go b/cmd/pro/start_flags.go index 4207071e34..9b8ad1b622 100644 --- a/cmd/pro/start_flags.go +++ b/cmd/pro/start_flags.go @@ -23,7 +23,7 @@ func (cmd *StartCmd) registerDockerFlags(startCmd *cobra.Command) { &cmd.Docker, names.Docker, false, - "If enabled will try to deploy Devsy Pro to the local docker installation.", + "If enabled will try to deploy Devsy Platform to the local docker installation.", ), cliflags.String(&cmd.DockerImage, names.DockerImage, "", "The docker image to install."), cliflags.StringArray(&cmd.DockerArgs, names.DockerArg, []string{}, "Extra docker args"), @@ -76,13 +76,13 @@ func (cmd *StartCmd) registerChartFlags(startCmd *cobra.Command) { &cmd.ChartPath, names.ChartPath, "", - "The local chart path to deploy Devsy Pro", + "The local chart path to deploy Devsy Platform", ), cliflags.String( &cmd.ChartRepo, names.ChartRepo, "https://charts.devsy.sh/", - "The chart repo to deploy Devsy Pro", + "The chart repo to deploy Devsy Platform", ), ) } @@ -113,7 +113,7 @@ func (cmd *StartCmd) registerLifecycleFlags(startCmd *cobra.Command) { &cmd.Reset, names.Reset, false, - "If true, an existing instance will be deleted before installing Devsy Pro", + "If true, an existing instance will be deleted before installing Devsy Platform", ), cliflags.Bool( &cmd.NoWait, @@ -131,7 +131,7 @@ func (cmd *StartCmd) registerLifecycleFlags(startCmd *cobra.Command) { &cmd.NoLogin, names.NoLogin, false, - "If true, will not login to a Devsy Pro instance on start", + "If true, will not login to a Devsy Platform instance on start", ), ) } diff --git a/cmd/pro/start_uninstall.go b/cmd/pro/start_uninstall.go index c34110d90d..9d00f1f10f 100644 --- a/cmd/pro/start_uninstall.go +++ b/cmd/pro/start_uninstall.go @@ -17,13 +17,13 @@ import ( "k8s.io/kube-aggregator/pkg/client/clientset_generated/clientset" ) -// uninstallTarget identifies the kube context and namespace Devsy Pro is installed in. +// uninstallTarget identifies the kube context and namespace Devsy Platform is installed in. type uninstallTarget struct { kubeContext string namespace string } -// Helm flags used when uninstalling Devsy Pro. +// Helm flags used when uninstalling Devsy Platform. const ( helmKubeContextFlag = "--kube-context" helmNamespaceFlag = "--namespace" @@ -44,7 +44,7 @@ func uninstall( } fmt.Fprint(os.Stderr, "\n") - log.Info("uninstalled Devsy Pro") + log.Info("uninstalled Devsy Platform") fmt.Fprint(os.Stderr, "\n") return nil diff --git a/pkg/config/env.go b/pkg/config/env.go index acb4b9b63e..ff3efe9d54 100644 --- a/pkg/config/env.go +++ b/pkg/config/env.go @@ -39,7 +39,7 @@ const ( // EnvDisableTelemetry disables telemetry collection. EnvDisableTelemetry = "DEVSY_DISABLE_TELEMETRY" - // EnvPlatformRunner is set by the Devsy Pro runner pod to mark runner-side CLI invocations. + // EnvPlatformRunner is set by the Devsy Platform runner pod to mark runner-side CLI invocations. EnvPlatformRunner = "DEVSY_PRO_RUNNER" // EnvTelemetryDistinctID is set by the desktop app on spawned CLI @@ -114,7 +114,7 @@ const ( // EnvFlagsStatus holds extra flags for the status command. EnvFlagsStatus = "DEVSY_FLAGS_STATUS" - // EnvSubdomain is the subdomain configuration for Devsy Pro. + // EnvSubdomain is the subdomain configuration for Devsy Platform. EnvSubdomain = "DEVSY_SUBDOMAIN" // EnvPrefix is the base prefix for all Devsy environment variables. diff --git a/pkg/config/product.go b/pkg/config/product.go index 863a0d88d1..e75b16912b 100644 --- a/pkg/config/product.go +++ b/pkg/config/product.go @@ -4,8 +4,8 @@ const ( // ProductName is the display name for the product. ProductName = "Devsy" - // ProductNamePro is the display name for the Pro product. - ProductNamePro = ProductName + " Pro" + // ProductNamePlatform is the display name for the Platform product. + ProductNamePlatform = ProductName + " Platform" // DaemonServiceDescription is the system daemon service description. DaemonServiceDescription = ProductName + " Agent Service" diff --git a/pkg/config/repo.go b/pkg/config/repo.go index 2dc49ff7ad..6cc54bfd33 100644 --- a/pkg/config/repo.go +++ b/pkg/config/repo.go @@ -16,7 +16,7 @@ const ( GitHubAPIUserURL = "https://api.github.com/users/" + RepoOwner ProviderPrefix = RepoName + "-provider-" - // PlatformReleaseName is the Helm release / product name for Devsy Pro. + // PlatformReleaseName is the Helm release / product name for Devsy Platform. PlatformReleaseName = RepoName + "-pro" // BinaryName is the CLI binary base name used in downloads and SSH host suffixes. diff --git a/pkg/devcontainer/buildkit/remote.go b/pkg/devcontainer/buildkit/remote.go index d8137a3404..b46736d7e6 100644 --- a/pkg/devcontainer/buildkit/remote.go +++ b/pkg/devcontainer/buildkit/remote.go @@ -133,7 +133,7 @@ func validateRemoteBuildOptions(options provider.BuildOptions) error { return fmt.Errorf("cannot build in this mode, rebuild the container with up command") } if !options.CLIOptions.Platform.Enabled { - return errors.New("remote builds are only supported in Devsy Pro") + return errors.New("remote builds are only supported in Devsy Platform") } if options.CLIOptions.Platform.Build == nil { return errors.New("build options are required for remote builds") diff --git a/pkg/platform/client/client.go b/pkg/platform/client/client.go index 6f77bb7246..36e24e2438 100644 --- a/pkg/platform/client/client.go +++ b/pkg/platform/client/client.go @@ -300,7 +300,7 @@ func (c *client) Login(host string, insecure bool) error { } msg += "'" log.Infof(msg, host, pkgconfig.BinaryName+" pro login", host) - log.Infof("Logging into Devsy Pro") + log.Infof("Logging into Devsy Platform") key = <-keyChannel @@ -460,7 +460,7 @@ func VerifyVersion(baseClient Client) error { return fmt.Errorf( "unsupported %[1]s version %[2]s. Downgrade your CLI to below v%[3]d.0.0 to support this version, "+ "as %[1]s v%[3]d.0.0 and newer versions are incompatible with v%[4]d.x.x", - pkgconfig.ProductNamePro, + pkgconfig.ProductNamePlatform, v.Version, cliVersion.Major, backendMajor, @@ -469,7 +469,7 @@ func VerifyVersion(baseClient Client) error { return fmt.Errorf( "unsupported %[1]s version %[2]s. Upgrade your CLI to v%[3]d.0.0 or above to support this version, "+ "as %[1]s v%[3]d.0.0 and newer versions are incompatible with v%[4]d.x.x", - pkgconfig.ProductNamePro, + pkgconfig.ProductNamePlatform, v.Version, backendMajor, cliVersion.Major, diff --git a/pkg/platform/deploy.go b/pkg/platform/deploy.go index 1064d17c3f..4b46c9fef1 100644 --- a/pkg/platform/deploy.go +++ b/pkg/platform/deploy.go @@ -104,12 +104,12 @@ func latestDevsyPod( LabelSelector: "app=devsy", }) if err != nil { - log.Warnf("Error trying to retrieve %s pod: %v", pkgconfig.ProductNamePro, err) + log.Warnf("Error trying to retrieve %s pod: %v", pkgconfig.ProductNamePlatform, err) return nil } if len(pods.Items) == 0 { if time.Now().After(now.Add(time.Second * 10)) { - log.Infof("Still waiting for a %s pod", pkgconfig.ProductNamePro) + log.Infof("Still waiting for a %s pod", pkgconfig.ProductNamePlatform) *now = time.Now() } return nil @@ -169,7 +169,7 @@ func devsyPodFailureError(params evalContainerStatusParams) error { if err != nil { return fmt.Errorf( "there seems to be an issue with %s starting up: %s (%s). Reach out to our support at https://devsy.sh/", - pkgconfig.ProductNamePro, + pkgconfig.ProductNamePlatform, message, reason, ) @@ -182,7 +182,7 @@ func devsyPodFailureError(params evalContainerStatusParams) error { "%[1]s logs: \n%[2]v \nThere seems to be an issue with %[1]s starting up. "+ "Looks like you try to install %[1]s into an air-gapped environment, "+ "reach out to our support at https://devsy.sh/ for an offline license", - pkgconfig.ProductNamePro, + pkgconfig.ProductNamePlatform, string(out), ) } @@ -190,7 +190,7 @@ func devsyPodFailureError(params evalContainerStatusParams) error { return fmt.Errorf( "%[1]s logs: \n%[2]v \nThere seems to be an issue with %[1]s starting up: %[3]s (%[4]s). "+ "Reach out to our support at https://devsy.sh/", - pkgconfig.ProductNamePro, + pkgconfig.ProductNamePlatform, string(out), message, reason, @@ -202,20 +202,20 @@ func logContainerWaiting(containerStatus corev1.ContainerStatus) { case containerStatus.State.Waiting.Message != "": log.Infof( "Keep waiting, %s container is still starting up: %s (%s)", - pkgconfig.ProductNamePro, + pkgconfig.ProductNamePlatform, containerStatus.State.Waiting.Message, containerStatus.State.Waiting.Reason, ) case containerStatus.State.Waiting.Reason != "": log.Infof( "Keep waiting, %s container is still starting up: %s", - pkgconfig.ProductNamePro, + pkgconfig.ProductNamePlatform, containerStatus.State.Waiting.Reason, ) default: log.Infof( "Keep waiting, %s container is still starting up", - pkgconfig.ProductNamePro, + pkgconfig.ProductNamePlatform, ) } }