New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue #2900 add write-config flag and cluster start #2903
Conversation
b05da55
to
37196ce
Compare
37196ce
to
8a8c0cd
Compare
@praveenkumar In terms of directories in /var/lib/minishift/base I think I see the same number of directories. Can you please point me the config file that gets created with --write-config? |
@praveenkumar Also wondering what is the downside of enabling |
@LalatenduMohanty it will not create any other directory but this is the flag to create the config directory without initiating the cluster up. |
CI failure is not related to this PR.
|
@praveenkumar This PR is failing for me consistently , can you take a look?
|
clusterUpFlagSet = cmdUtil.InitClusterUpFlags("start") | ||
startCmd.Flags().AddFlagSet(clusterUpFlagSet) | ||
OpenShiftCmd.AddCommand(startCmd) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@praveenkumar I found during my testing that minishift openshift start
is not behind the experimental flag and also did not find any code for the same.
@LalatenduMohanty I tried on clean environment and it works as expected (xhyve), @amitkrout @agajdosi any one of you can try it and let me know if you are facing similar issue? $ ./minishift start --write-config
-- Starting profile 'minishift'
-- Check if deprecated options are used ... OK
-- Checking if https://github.com is reachable ... OK
-- Checking if requested OpenShift version 'v3.11.0' is valid ... OK
-- Checking if requested OpenShift version 'v3.11.0' is supported ... OK
-- Checking if requested hypervisor 'xhyve' is supported on this platform ... OK
-- Checking if xhyve driver is installed ...
Driver is available at /usr/local/bin/docker-machine-driver-xhyve
Checking for setuid bit ... OK
-- Checking the ISO URL ... OK
-- Checking if provided oc flags are supported ... OK
-- Starting the OpenShift cluster using 'xhyve' hypervisor ...
-- Minishift VM will be configured with ...
Memory: 4 GB
vCPUs : 2
Disk size: 20 GB
-- Starting Minishift VM ...................... OK
-- Checking for IP address ... OK
-- Checking for nameservers ... OK
-- Checking if external host is reachable from the Minishift VM ...
Pinging 8.8.8.8 ... OK
-- Checking HTTP connectivity from the VM ...
Retrieving http://minishift.io/index.html ... OK
-- Checking if persistent storage volume is mounted ... OK
-- Checking available disk space ... 1% used OK
-- Writing current configuration for static assignment of IP address ... OK
Importing 'docker.io/openshift/origin-cli:v3.11.0' ........ OK
Importing 'docker.io/openshift/origin-control-plane:v3.11.0' ............. OK
Importing 'docker.io/openshift/origin-deployer:v3.11.0' .... OK
Importing 'docker.io/openshift/origin-docker-registry:v3.11.0' .... OK
Importing 'docker.io/openshift/origin-haproxy-router:v3.11.0' .... OK
Importing 'docker.io/openshift/origin-hyperkube:v3.11.0' ...... OK
Importing 'docker.io/openshift/origin-hypershift:v3.11.0' ......... OK
Importing 'docker.io/openshift/origin-node:v3.11.0' ................ OK
Importing 'docker.io/openshift/origin-pod:v3.11.0' .... OK
Importing 'docker.io/openshift/origin-service-serving-cert-signer:v3.11' ... OK
Importing 'docker.io/openshift/origin-web-console:v3.11.0' ..... OK
Importing 'openshift/origin-control-plane:v3.11.0' ........... OK
Importing 'openshift/origin-docker-registry:v3.11.0' ... OK
Importing 'openshift/origin-haproxy-router:v3.11.0' ..... OK
-- OpenShift cluster will be configured with ...
Version: v3.11.0
-- Copying oc binary from the OpenShift container image to VM ... OK
-- Starting OpenShift cluster ...
Getting a Docker client ...
Checking if image openshift/origin-control-plane:v3.11.0 is available ...
Checking type of volume mount ...
Determining server IP ...
Using public hostname IP 192.168.64.74 as the host IP
Checking if OpenShift is already running ...
Checking for supported Docker version (=>1.22) ...
Checking if insecured registry is configured properly in Docker ...
Checking if required ports are available ...
Checking if OpenShift client is configured properly ...
Checking if image openshift/origin-control-plane:v3.11.0 is available ...
Starting OpenShift using openshift/origin-control-plane:v3.11.0 ...
I1112 08:33:54.984154 2386 config.go:40] Running "create-master-config"
I1112 08:33:57.525427 2386 config.go:46] Running "create-node-config"
Wrote config to: "/var/lib/minishift/base"
$ ./minishift openshift start
..................................................................................
Getting a Docker client ...
Checking if image openshift/origin-control-plane:v3.11.0 is available ...
Checking type of volume mount ...
Determining server IP ...
Using public hostname IP 192.168.64.74 as the host IP
Checking if OpenShift is already running ...
Checking for supported Docker version (=>1.22) ...
Checking if insecured registry is configured properly in Docker ...
Checking if required ports are available ...
Checking if OpenShift client is configured properly ...
Checking if image openshift/origin-control-plane:v3.11.0 is available ...
Starting OpenShift using openshift/origin-control-plane:v3.11.0 ...
I1112 08:38:12.482161 2788 flags.go:30] Running "create-kubelet-flags"
I1112 08:38:12.878182 2788 run_kubelet.go:49] Running "start-kubelet"
I1112 08:38:13.071623 2788 run_self_hosted.go:181] Waiting for the kube-apiserver to be ready ...
I1112 08:42:09.118205 2788 interface.go:26] Installing "kube-proxy" ...
I1112 08:42:09.121060 2788 interface.go:26] Installing "kube-dns" ...
I1112 08:42:09.121102 2788 interface.go:26] Installing "openshift-service-cert-signer-operator" ...
I1112 08:42:09.121127 2788 interface.go:26] Installing "openshift-apiserver" ...
I1112 08:42:09.121972 2788 apply_template.go:81] Installing "openshift-apiserver"
I1112 08:42:09.122643 2788 apply_template.go:81] Installing "kube-proxy"
I1112 08:42:09.124186 2788 apply_template.go:81] Installing "kube-dns"
I1112 08:42:09.125470 2788 apply_template.go:81] Installing "openshift-service-cert-signer-operator"
I1112 08:42:21.793082 2788 interface.go:41] Finished installing "kube-proxy" "kube-dns" "openshift-service-cert-signer-operator" "openshift-apiserver"
I1112 08:44:45.872031 2788 run_self_hosted.go:242] openshift-apiserver available
I1112 08:44:45.873271 2788 interface.go:26] Installing "openshift-controller-manager" ...
I1112 08:44:45.873389 2788 apply_template.go:81] Installing "openshift-controller-manager"
I1112 08:44:52.552233 2788 interface.go:41] Finished installing "openshift-controller-manager"
Adding default OAuthClient redirect URIs ...
Adding persistent-volumes ...
Adding web-console ...
Adding router ...
Adding registry ...
Adding sample-templates ...
Adding centos-imagestreams ...
I1112 08:44:52.615260 2788 interface.go:26] Installing "persistent-volumes" ...
I1112 08:44:52.615310 2788 interface.go:26] Installing "openshift-web-console-operator" ...
I1112 08:44:52.615338 2788 interface.go:26] Installing "openshift-router" ...
I1112 08:44:52.615363 2788 interface.go:26] Installing "openshift-image-registry" ...
I1112 08:44:52.615389 2788 interface.go:26] Installing "sample-templates" ...
I1112 08:44:52.615436 2788 interface.go:26] Installing "centos-imagestreams" ...
I1112 08:44:52.615607 2788 apply_list.go:67] Installing "centos-imagestreams"
I1112 08:44:52.617071 2788 apply_template.go:81] Installing "openshift-web-console-operator"
I1112 08:44:52.618462 2788 interface.go:26] Installing "sample-templates/mariadb" ...
I1112 08:44:52.618495 2788 interface.go:26] Installing "sample-templates/dancer quickstart" ...
I1112 08:44:52.618521 2788 interface.go:26] Installing "sample-templates/django quickstart" ...
I1112 08:44:52.618547 2788 interface.go:26] Installing "sample-templates/rails quickstart" ...
I1112 08:44:52.618572 2788 interface.go:26] Installing "sample-templates/jenkins pipeline ephemeral" ...
I1112 08:44:52.618598 2788 interface.go:26] Installing "sample-templates/sample pipeline" ...
I1112 08:44:52.618623 2788 interface.go:26] Installing "sample-templates/mongodb" ...
I1112 08:44:52.618647 2788 interface.go:26] Installing "sample-templates/mysql" ...
I1112 08:44:52.618674 2788 interface.go:26] Installing "sample-templates/postgresql" ...
I1112 08:44:52.618699 2788 interface.go:26] Installing "sample-templates/cakephp quickstart" ...
I1112 08:44:52.618724 2788 interface.go:26] Installing "sample-templates/nodejs quickstart" ...
I1112 08:44:52.618811 2788 apply_list.go:67] Installing "sample-templates/nodejs quickstart"
I1112 08:44:52.619226 2788 apply_list.go:67] Installing "sample-templates/mariadb"
I1112 08:44:52.619461 2788 apply_list.go:67] Installing "sample-templates/dancer quickstart"
I1112 08:44:52.619702 2788 apply_list.go:67] Installing "sample-templates/django quickstart"
I1112 08:44:52.619987 2788 apply_list.go:67] Installing "sample-templates/rails quickstart"
I1112 08:44:52.620249 2788 apply_list.go:67] Installing "sample-templates/jenkins pipeline ephemeral"
I1112 08:44:52.620474 2788 apply_list.go:67] Installing "sample-templates/sample pipeline"
I1112 08:44:52.620700 2788 apply_list.go:67] Installing "sample-templates/mongodb"
I1112 08:44:52.620987 2788 apply_list.go:67] Installing "sample-templates/mysql"
I1112 08:44:52.621255 2788 apply_list.go:67] Installing "sample-templates/postgresql"
I1112 08:44:52.621521 2788 apply_list.go:67] Installing "sample-templates/cakephp quickstart"
I1112 08:45:19.638190 2788 interface.go:41] Finished installing "sample-templates/mariadb" "sample-templates/dancer quickstart" "sample-templates/django quickstart" "sample-templates/rails quickstart" "sample-templates/jenkins pipeline ephemeral" "sample-templates/sample pipeline" "sample-templates/mongodb" "sample-templates/mysql" "sample-templates/postgresql" "sample-templates/cakephp quickstart" "sample-templates/nodejs quickstart"
I1112 08:45:46.546186 2788 interface.go:41] Finished installing "persistent-volumes" "openshift-web-console-operator" "openshift-router" "openshift-image-registry" "sample-templates" "centos-imagestreams"
Login to server ...
Creating initial project "myproject" ...
Server Information ...
OpenShift server started.
The server is accessible via web console at:
https://192.168.64.74:8443/console
You are logged in as:
User: developer
Password: <any value>
To login as administrator:
oc login -u system:admin
OpenShift Started successfully |
8a8c0cd
to
862a4ec
Compare
Codecov Report
@@ Coverage Diff @@
## master #2903 +/- ##
==========================================
- Coverage 28.14% 25.87% -2.27%
==========================================
Files 148 149 +1
Lines 7724 7775 +51
==========================================
- Hits 2174 2012 -162
- Misses 5267 5509 +242
+ Partials 283 254 -29
|
Works fine and deployed the default nodejs app on the same running cluster. No failure as such Tested on - fedora 29 + kvm |
@praveenkumar How this is differ from our regular Can you please add a feature file or create test coverage issue, will take it in the current sprint. |
@amitkrout This is not going to replace current
@amitkrout I can create a follow-up the issue once it merges about the test coverage. Since it is just an experimental feature so not going to affect our generic workflow. |
@praveenkumar I was expecting that --write-config will take some parameters to be added, written to config file. One can run it just as you mention in example code above: Thank you for help, feeling lost in it right now 😰 . |
@agajdosi AFAIU
And to consume this change run |
@amitkrout that's right, @agajdosi so this is nothing to do with our openshift patch command stuff, it is mostly for debug purpose for the specific config change. |
Tested again and it is working fine. |
Fixes #2900
Steps to test the pull request