This is a Docker Compose file for running a Rancher server. Rancher is an open-source platform that enables organizations to run and manage Docker and Kubernetes in production. It includes a full Kubernetes distribution, but adds additional features such as multi-tenancy, community catalog, and more. This Docker Compose file uses version 3.9.
The compose file defines a single service: rancher
.
The Rancher service uses the latest Rancher image from Docker Hub. It runs in privileged mode and exposes ports 80 and 443. It also mounts a volume rancher_home
at /var/lib/rancher
in the container.
The compose file defines a single volume: rancher_home
. This volume is used by the Rancher service.
docker-compose up
Grab the helm command from port 80
docker ps
the docker exec -it <container_id> bash
then paste what you copied for helm installation.
Run
To add a Helm repository, use the helm repo add
command. For example, to add the Bitnami repository:
helm repo add bitnami https://charts.bitnami.com/bitnami
helm install my-nginx bitnami/nginx