github.com/freiheit-com/kuberpult@v1.24.2-0.20240328135542-315d5630abe6/tests/integration-tests/cluster-setup/docker-compose-k3s.yml (about) 1 # to run define K3S_TOKEN, K3S_VERSION is optional, eg: 2 # K3S_TOKEN=${RANDOM}${RANDOM}${RANDOM} docker-compose up 3 4 version: '3' 5 services: 6 7 server: 8 image: "rancher/k3s:${K3S_VERSION:-latest}" 9 command: server 10 tmpfs: 11 - /run 12 - /var/run 13 ulimits: 14 nproc: 65535 15 nofile: 16 soft: 65535 17 hard: 65535 18 privileged: true 19 restart: always 20 environment: 21 - K3S_TOKEN=${K3S_TOKEN:?err} 22 - K3S_KUBECONFIG_OUTPUT=/output/kubeconfig.yaml 23 - K3S_KUBECONFIG_MODE=666 24 volumes: 25 - k3s-server:/var/lib/rancher/k3s 26 # This is just so that we get the kubeconfig file out 27 - .:/output 28 ports: 29 - 6443:6443 # Kubernetes API Server 30 - 80:80 # Ingress controller port 80 31 - 443:443 # Ingress controller port 443 32 33 agent: 34 image: "rancher/k3s:${K3S_VERSION:-latest}" 35 tmpfs: 36 - /run 37 - /var/run 38 ulimits: 39 nproc: 65535 40 nofile: 41 soft: 65535 42 hard: 65535 43 privileged: true 44 restart: always 45 environment: 46 - K3S_URL=https://server:6443 47 - K3S_TOKEN=${K3S_TOKEN:?err} 48 49 volumes: 50 k3s-server: {}