Skip to content
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

Adding steps for how to use existing cluster as bootstrap cluster. #877

Merged
merged 1 commit into from
Apr 5, 2019

Conversation

gyliu513
Copy link
Contributor

@gyliu513 gyliu513 commented Apr 4, 2019

What this PR does / why we need it:

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #825

Special notes for your reviewer:

Please confirm that if this PR changes any image versions, then that's the sole change this PR makes.

Release note:

Adding steps for how to use existing cluster as bootstrap cluster.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Apr 4, 2019
@k8s-ci-robot k8s-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Apr 4, 2019
@gyliu513
Copy link
Contributor Author

gyliu513 commented Apr 4, 2019

/cc @jichenjc

@k8s-ci-robot k8s-ci-robot requested a review from jichenjc April 4, 2019 09:12
@detiber
Copy link
Member

detiber commented Apr 4, 2019

/assign @amy

@k8s-ci-robot
Copy link
Contributor

@detiber: GitHub didn't allow me to assign the following users: amy.

Note that only kubernetes-sigs members and repo collaborators can be assigned and that issues/PRs can only have 10 assignees at the same time.
For more information please see the contributor guide

In response to this:

/assign @amy

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@jichenjc
Copy link
Contributor

jichenjc commented Apr 4, 2019

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 4, 2019
@jichenjc
Copy link
Contributor

jichenjc commented Apr 4, 2019

I tried this command with existing minikube env on openstack provider
I found some bug though but it's not related to the existing cluster feature, the command for existing cluster does work

2. If you are using kind, go to step 3; If you are using minikube, install a [driver](https://github.com/kubernetes/minikube/blob/master/docs/drivers.md) for minikube. For Linux, we recommend kvm2. For MacOS, we recommend VirtualBox.
1. You can use either VM, container or existing Kubernetes cluster act as bootstrap cluster, it is recommended to use container or existing Kubernetes cluster.
- If you want to use VM, install [minikube](https://kubernetes.io/docs/tasks/tools/install-minikube/), version 0.30.0 or greater.
- If you want to use container, install [kind](https://github.com/kubernetes-sigs/kind#installation-and-usage).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we mark kind as the preferred mechanism?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

- If you want to use VM, install [minikube](https://kubernetes.io/docs/tasks/tools/install-minikube/), version 0.30.0 or greater.
- If you want to use container, install [kind](https://github.com/kubernetes-sigs/kind#installation-and-usage).
- If you want to use existing Kubernetes cluster, prepare your kubeconfig.
2. If you are using kind or existing Kubernetes cluster, go to step 3; If you are using minikube, install a [driver](https://github.com/kubernetes/minikube/blob/master/docs/drivers.md) for minikube. For Linux, we recommend kvm2. For MacOS, we recommend VirtualBox.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
2. If you are using kind or existing Kubernetes cluster, go to step 3; If you are using minikube, install a [driver](https://github.com/kubernetes/minikube/blob/master/docs/drivers.md) for minikube. For Linux, we recommend kvm2. For MacOS, we recommend VirtualBox.
2. If you are using `kind` or existing Kubernetes cluster, go to step 3. If you are using `minikube`, install a [driver](https://github.com/kubernetes/minikube/blob/master/docs/drivers.md). For Linux, we recommend `kvm2`. For MacOS, we recommend VirtualBox.

@@ -40,13 +43,21 @@ https://github.com/kubernetes-sigs/cluster-api/issues/158 and https://github.com

1. Create a cluster:

- With `bootstrap-type`. Currently two `bootstrap-type` options are supported - `kind` and `minikube`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- With `bootstrap-type`. Currently two `bootstrap-type` options are supported - `kind` and `minikube`.
- __Bootstrap Cluster__: Use `bootstrap-type`, currently only `kind` and `minikube` are supported.

Currently two `bootstrap-type` options are supported - `kind` and `minikube`.
If you are using minikube, to choose a specific minikube driver, please use the `--bootstrap-flags vm-driver=xxx` command line parameter. For example to use the kvm2 driver with clusterctl you woud add `--bootstrap-flags vm-driver=kvm2`.

- With `bootstrap-cluster-kubeconfig`, this is used when you are using an existing Kubernetes cluster as your bootstrap cluster.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- With `bootstrap-cluster-kubeconfig`, this is used when you are using an existing Kubernetes cluster as your bootstrap cluster.
- __Existing Cluster__: Use `bootstrap-cluster-kubeconfig`. This flag is used when you have an existing Kubernetes cluster.

@@ -13,8 +13,11 @@ this repository.**

### Prerequisites

1. Install [kind](https://github.com/kubernetes-sigs/kind#installation-and-usage) or [minikube](https://kubernetes.io/docs/tasks/tools/install-minikube/). [kind](https://github.com/kubernetes-sigs/kind#installation-and-usage) is preferred.
2. If you are using kind, go to step 3; If you are using minikube, install a [driver](https://github.com/kubernetes/minikube/blob/master/docs/drivers.md) for minikube. For Linux, we recommend kvm2. For MacOS, we recommend VirtualBox.
1. You can use either VM, container or existing Kubernetes cluster act as bootstrap cluster, it is recommended to use container or existing Kubernetes cluster.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
1. You can use either VM, container or existing Kubernetes cluster act as bootstrap cluster, it is recommended to use container or existing Kubernetes cluster.
1. Cluster API runs its operations in Kubernetes. A pre-existing or temporary bootstrap cluster is required. Currently, we support multiple methods to bootstrap Cluster API: `kind` (preferred), `minikube` or any pre-existing cluster.

@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 5, 2019
@jichenjc
Copy link
Contributor

jichenjc commented Apr 5, 2019

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 5, 2019
@detiber
Copy link
Member

detiber commented Apr 5, 2019

+1 from me

@vincepri
Copy link
Member

vincepri commented Apr 5, 2019

/approve

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: gyliu513, vincepri

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 5, 2019
@k8s-ci-robot k8s-ci-robot merged commit 2d14f02 into kubernetes-sigs:master Apr 5, 2019
@gyliu513 gyliu513 deleted the existing-cluster branch April 6, 2019 02:01
k8s-ci-robot pushed a commit that referenced this pull request Jun 7, 2019
* Adding steps for how to use existing cluster as bootstrap cluster. (#877)

* Add proposals template (#879)

Signed-off-by: Vince Prignano <[email protected]>

* Clarify how to use kuebconfig. (#869)

* Add discuss link to README (#885)

Signed-off-by: Vince Prignano <[email protected]>

* Fix a broken link to Cluster API KEP (#900)

* Add Cluster API project scope and objectives (#882)

Signed-off-by: Vince Prignano <[email protected]>

* Fix API group name written in kubebuilder's annotation comments (#883)

* Update github org for the baremetal provider. (#911)

The github org was renamed, so use the new URL for the location of the
bare metal cluster-api provider.

* Add Talos to list of providers (#915)

* Add reference use cases for Cluster API (#903)

Signed-off-by: Vince Prignano <[email protected]>

* Add missing bullet point to staging-use-cases.md (#920)

* Added IBM Cloud to Cluster API README. (#928)

* Update documentation links to published content (#927)

* Add Cluster API logos from CNCF (#916)

* Adding Reference Use Cases to README. (#931)

* Updating release docs for branching approach now that we are 0.x (#862)

I think the previous approach was for pre-versioned branches, but now
we probably want to start maintaining release branches - even if in
practice we would cut 0.2.0 instead of 0.1.1

* Used doctoc generated toc. (#932)

* Update to go 1.12.5 (#937)

* Attempt to fix integration tests (#942)

- Use specific versions of kind and kustomize instead of installing
  with `go get`
- Update golang version for example provider

* Update README.md (#941)

* Add shortnames for crds. (#943)

* Fix machine object pivoting to the target cluster (#944)

* [docs] Update RBAC annotations for example provider (#947)

* Remove workstreams from scope and objectives (#948)

Signed-off-by: Vince Prignano <[email protected]>

* Added ibm cloud to architecture diagram. (#946)

* Added comment about cluster API vs cloud providers to readme (#954)

* Quit MachineSet reconcile early if DeletionTimestamp is set (#956)

Signed-off-by: Vince Prignano <[email protected]>

* Cleanup controllers (#958)

Signed-off-by: Vince Prignano <[email protected]>

* updates Google Cloud branding to mach other usages (#973)

* Cannot retrieve machine name (#960)

Signed-off-by: clyang82 <[email protected]>

* Allow to use foregroundDeletion for MachineDeployments and MachineSets (#953)

* Rename controllers test files (#968)

Signed-off-by: Vince Prignano <[email protected]>

* make cluster-api-manager container run with a non-root user (#955)

* Update Gitbook release process (#659)

* Remove mermaid module because it is currently unused and does not
always install cleanly.

* Introduce npm-shrinkwrap so that npm installations are reproducable.

* Update gitbook release documentation.

* Clarify verification instructions.

* Update GitBook.

* Remove rendered Gitbook from repo in preparation for using firebase
instead.

* Install gitbook cli.

* Update documentation for netlify.

* Add Netlify configuration toml.

* Update link to homepage so that it points to the book and not
the GitHub repository.

* Remove base from netlify.toml. The build script already accounts
for the correct location...

* Remove reference to no longer existent KEP. :(

* Disable redirects until the cluster-api.sigs.k8s.io domain has
been created.

* Reenable netlify redirects now that the cluster-api.sigs.k8s.io
domain exists.

* Add versioning and releases to README (#967)

Signed-off-by: Vince Prignano <[email protected]>

* Add more log for cluster deletion failure (#978)

* Update dependencies (#982)

Signed-off-by: Vince Prignano <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Document] How to provision a k8s cluster with an existing k8s cluster but not bootstrap cluster?
5 participants