1

So far (v2.1 Beta) the solution is to:

1) go up to the upper right-hand corner and click on the user profile (e.g. admin).
2) A menu will unfold with 4 options: Sign out, Change Password, Configure Client and About.
3) Click Configure Client which will present you with a dialog of 4-5 kubectl invocations which include user specific tokens, etc.
4) Copy and paste that text into your command line terminal, and hit enter.

You should then be all set. If you run into a blank dialog, then refresh the entire browser page and try again, it will populate.

However, I want to know if anyone has found a better way to do it?

timmy
  • 21
  • 3

2 Answers2

0

With ICp 2.1 beta, user actually can install an application from App Center which provides the web terminal for kubectl, helm, and also calicoctl, the detailed steps would be: 1. install `local-charts/web-terminal` from App center 2. go to Workload->Application->default-web-terminal-web 3. click to open the Endpoint page 4. admin/admin as credential

0

In 2.1.0 Beta3, the first version of the command line tools are available for IBM Cloud Private.

These tools can be installed on your platform of choice from the "Tools > Command Line" option in the webconsole.

bx pr login -a https://mycluster.icp:8443 -u admin --skip-ssl-validation
Login method invokedAPI endpoint: https://mycluster.icp:8443

Password> 
Authenticating...
OK

Select an account:
1. ICP Account (9335b8949793c6fb1b96cf2a103a9d50)
Enter a number> 1
Targeted account: ICP Account (9335b8949793c6fb1b96cf2a103a9d50)

bx pr clusters
OK
Name        ID                                 State      Created                    Masters   Workers   Datacenter   
mycluster   00000000000000000000000000000001   deployed   2017-10-13T03:28:53+0000   1         3         default   

bx pr cluster-config mycluster
Configuring kubectl: /Users/mdelder/.bluemix/plugins/icp/clusters/mycluster/kube-config
Cluster "master.cfc" set.
Context "master.cfc-context" set.
User "master.cfc-user" set.
Context "master.cfc-context" set.
Switched to context "master.cfc-context".

OK
Cluster mycluster configured successfully.

Now you can use kubectl:

kubectl get nodes
NAME          STATUS    AGE       VERSION
10.10.25.27   Ready     2d        v1.7.3-7+154699da4767fd
10.10.25.28   Ready     2d        v1.7.3-7+154699da4767fd
10.10.25.72   Ready     2d        v1.7.3-7+154699da4767fd
10.10.25.73   Ready     2d        v1.7.3-7+154699da4767fd

You can also discover information about your cluster:

bx pr help

NAME:
   bx pr - IBM Cloud Private Service.
USAGE:
   bx pr command [arguments...] [command options]

COMMANDS:
   api                View or set the API endpoint and API version for the service.
   cluster-config     Download the Kubernetes configuration and configure kubectl for a specified cluster.
   cluster-get        View details for a cluster.
   clusters           List all the clusters in your account.
   init               Initialize the IBM Cloud Private plugin with the API endpoint.
   load-helm-chart    Loads a Helm chart archive to an IBM Cloud Private cluster.
   load-ppa-archive   Load Docker images and Helm charts compressed file that you downloaded from Passport Advantage.
   login              Log user in.
   master-get         View the details about a master node.
   masters            List all master nodes in an existing cluster.
   worker-get         View the details about a worker node.
   workers            List all worker nodes in an existing cluster.
   help               

Enter 'bx pr help [command]' for more information about a command.

bx pr masters mycluster
OK
ID                      Public IP     Private IP    State   
mycluster-00000000-m1   10.10.25.73   10.10.25.73   deployed 
Michael Elder
  • 246
  • 1
  • 3