From 9ae33c462e59071fd5a3f8b20535ef1ca0100c6b Mon Sep 17 00:00:00 2001 From: Daniel Cleyrat Date: Tue, 30 Apr 2024 10:13:23 -0700 Subject: [PATCH 1/2] fix: update endpoints to swc domain --- README.md | 6 +++--- cmd/datactl/app/config/config_init.go | 4 ++-- docs/datactl_config_init.md | 2 +- pkg/datactl/api/types.go | 4 ++-- pkg/datactl/api/v1/types.go | 2 +- 5 files changed, 9 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index d98419b..1b892f9 100644 --- a/README.md +++ b/README.md @@ -37,7 +37,7 @@ Datactl tool can be used standalone. Just move oc-datactl to your path and use ` 2. Log in to your cluster. -3. Setup your configuration. When prompted, provide the [pull secret token](https://marketplace.redhat.com/) as the `Upload API Secret`. +3. Setup your configuration. When prompted, provide the [pull secret token](https://swc.saas.ibm.com/) as the `Upload API Secret`. ```sh oc datactl config init @@ -132,12 +132,12 @@ A containerized FIPS enabled version of datactl is provided, built with Red Hat' ``` mkdir -p $HOME/.datactl ``` -2. Setup your configuration, binding the `.datactl` and `.kube` directories, and providing the marketplace api endpoint and [pull secret token](https://marketplace.redhat.com/en-us/account/keys) +2. Setup your configuration, binding the `.datactl` and `.kube` directories, and providing the marketplace api endpoint and [pull secret token](https://swc.saas.ibm.com/) ``` docker run --rm \ --mount type=bind,source=$HOME/.datactl,target=/root/.datactl \ --mount type=bind,source=$HOME/.kube,target=/root/.kube \ - quay.io/rh-marketplace/datactl:latest config init --api marketplace.redhat.com --token ${TOKEN} + quay.io/rh-marketplace/datactl:latest config init --api swc.saas.ibm.com --token ${TOKEN} ``` 3. Add a data source, such as `dataservice` from your current OpenShift cluster context ``` diff --git a/cmd/datactl/app/config/config_init.go b/cmd/datactl/app/config/config_init.go index 3d4e3da..0eecafe 100644 --- a/cmd/datactl/app/config/config_init.go +++ b/cmd/datactl/app/config/config_init.go @@ -40,7 +40,7 @@ var ( {{ .cmd }} config init # Initialize the config and preset upload URL and secret. Will not prompt. - {{ .cmd }} config init --api marketplace.redhat.com --token MY_TOKEN + {{ .cmd }} config init --api swc.saas.ibm.com --token MY_TOKEN `)) ) @@ -110,7 +110,7 @@ func (init *configInitOptions) runAPIEndpointPrompt() error { prompt := promptui.Prompt{ Label: "Upload API Endpoint", Validate: validate, - Default: "marketplace.redhat.com", + Default: "swc.saas.ibm.com", Stdin: io.NopCloser(init.In), Stdout: NopWCloser(init.Out), } diff --git a/docs/datactl_config_init.md b/docs/datactl_config_init.md index 94b25d6..cb332e7 100644 --- a/docs/datactl_config_init.md +++ b/docs/datactl_config_init.md @@ -17,7 +17,7 @@ datactl config init datactl config init # Initialize the config and preset upload URL and secret. Will not prompt. - datactl config init --api marketplace.redhat.com --token MY_TOKEN + datactl config init --api swc.saas.ibm.com --token MY_TOKEN ``` ### Options diff --git a/pkg/datactl/api/types.go b/pkg/datactl/api/types.go index 6653676..d8a082e 100644 --- a/pkg/datactl/api/types.go +++ b/pkg/datactl/api/types.go @@ -90,7 +90,7 @@ type UploadAPI struct { // +k8s:conversion-gen=false LocationOfOrigin string - // Host is the url of the marketplace i.e. marketplace.redhat.com + // Host is the url of the marketplace i.e. swc.saas.ibm.com Host string `json:"host"` // +optional @@ -179,7 +179,7 @@ func NewConfig() *Config { } const ( - marketplaceProductionUrl = "https://marketplace.redhat.come" + marketplaceProductionUrl = "https://swc.saas.ibm.com" ) func NewDefaultConfig(kube *genericclioptions.ConfigFlags) (*Config, error) { diff --git a/pkg/datactl/api/v1/types.go b/pkg/datactl/api/v1/types.go index 9d084db..7892f31 100644 --- a/pkg/datactl/api/v1/types.go +++ b/pkg/datactl/api/v1/types.go @@ -58,7 +58,7 @@ func (s *Source) String() string { } type UploadAPI struct { - // Host is the url of the marketplace i.e. marketplace.redhat.com + // Host is the url of the marketplace i.e. swc.saas.ibm.com Host string `json:"host"` // +optional From 9a03a6e4a7860b3b06d4d331c9a6b84f91fb3219 Mon Sep 17 00:00:00 2001 From: Daniel Cleyrat Date: Wed, 1 May 2024 05:50:33 -0700 Subject: [PATCH 2/2] fix: pull secret link, swc brand --- README.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 1b892f9..4acc954 100644 --- a/README.md +++ b/README.md @@ -33,11 +33,11 @@ Datactl tool can be used standalone. Just move oc-datactl to your path and use ` ## Getting started -1. Get your Red Hat Marketplace Pull Secret. +1. Get your Pull Secret. 2. Log in to your cluster. -3. Setup your configuration. When prompted, provide the [pull secret token](https://swc.saas.ibm.com/) as the `Upload API Secret`. +3. Setup your configuration. When prompted, provide the [pull secret token](https://swc.saas.ibm.com/en-us/account/keys) as the `Upload API Secret`. ```sh oc datactl config init @@ -92,13 +92,13 @@ Let's break down what each one is doing. `oc datactl export push` -- Files pulled by the previous command are pushed to Red Hat Marketplace. +- Files pulled by the previous command are pushed to IBM Software Central. - If this process errors, do not commit. Retry the export push or open a support ticket. `oc datactl export commit` - Commits the files to the dataservice. -- At this point you're telling the data service that you've retrieved these files and have or will submit them to Red Hat Marketplace. +- At this point you're telling the data service that you've retrieved these files and have or will submit them to IBM Software Central. - After some time, the files in dataservice will be cleaned up to save space. If you want to transfer it somewhere else, you can find the tar file under your `~/.datactl/data/` directory. @@ -119,7 +119,7 @@ To pull data from ILMT, execute command First time you will be asked to provide start date. Next time last synchronization date is stored in config file and will be updated to pull data from last synchronization date. -To push data to Red Hat Marketplace execute command +To push data to IBM Software Central execute command `datactl export push` @@ -132,7 +132,7 @@ A containerized FIPS enabled version of datactl is provided, built with Red Hat' ``` mkdir -p $HOME/.datactl ``` -2. Setup your configuration, binding the `.datactl` and `.kube` directories, and providing the marketplace api endpoint and [pull secret token](https://swc.saas.ibm.com/) +2. Setup your configuration, binding the `.datactl` and `.kube` directories, and providing the api endpoint and [pull secret token](https://swc.saas.ibm.com/en-us/account/keys) ``` docker run --rm \ --mount type=bind,source=$HOME/.datactl,target=/root/.datactl \ @@ -154,7 +154,7 @@ A containerized FIPS enabled version of datactl is provided, built with Red Hat' --mount type=bind,source=$HOME/.kube,target=/root/.kube \ quay.io/rh-marketplace/datactl:latest export pull ``` -5. Push data to Red Hat Marketplace +5. Push data to IBM Software Central ``` docker run --rm \ --name datactl \