mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2025-12-13 21:34:40 +03:00
README: add docker run (#11967)
* README: add docker run Signed-off-by: Loong <long0dai@foxmail.com> * Update README.md Co-authored-by: Robert Neumann <r0b2g1t@users.noreply.github.com> * Update README.md Co-authored-by: Robert Neumann <r0b2g1t@users.noreply.github.com> --------- Signed-off-by: Loong <long0dai@foxmail.com> Co-authored-by: Robert Neumann <r0b2g1t@users.noreply.github.com>
This commit is contained in:
12
README.md
12
README.md
@@ -15,6 +15,18 @@ You can get your invite [here](http://slack.k8s.io/)
|
||||
|
||||
Below are several ways to use Kubespray to deploy a Kubernetes cluster.
|
||||
|
||||
### Docker
|
||||
|
||||
Ensure you have installed Docker then
|
||||
|
||||
```ShellSession
|
||||
docker run --rm -it --mount type=bind,source="$(pwd)"/inventory/sample,dst=/inventory \
|
||||
--mount type=bind,source="${HOME}"/.ssh/id_rsa,dst=/root/.ssh/id_rsa \
|
||||
quay.io/kubespray/kubespray:v2.27.0 bash
|
||||
# Inside the container you may now run the kubespray playbooks:
|
||||
ansible-playbook -i /inventory/inventory.ini --private-key /root/.ssh/id_rsa cluster.yml
|
||||
```
|
||||
|
||||
### Ansible
|
||||
|
||||
#### Usage
|
||||
|
||||
Reference in New Issue
Block a user