resource "rke_cluster" "rancher" {
ssh_agent_auth = true
ignore_docker_version = true
kubernetes_version = var.kubernetes_version
dynamic "nodes" {
In this example I’ve three ‘controlplane’ nodes created as control{0..2} and five ‘worker’ nodes worker{0..5} created running openSUSE Leap 15.2.
All IP addresses assigned using DHCP, I’m using IP lookups via govc (https://github.com/vmware/govmomi/tree/master/govc#govc) as a poor man’s DNS.
Finally, I’m using k3sup (https://github.com/alexellis/k3sup) to bootstrap the installation.
Install the first node:
Tested with openSUSE Leap 15.2 and Docker CE 19.03.
Example RKE cluster.yml:
cluster_name: cilium
ssh_agent_auth: true
ignore_docker_version: true
kubernetes_version: "v1.19.7-rancher1-1"
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| """ | |
| scanreport.py | |
| Takes Rancher cis-operator ClusterScanReport JSON via stdin | |
| and formats it in a table | |
| Example usage: | |
| $ kubectl get clusterscanreport scan-report-rke-cis-1.5-hardened \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| ############################################## | |
| # Handle options | |
| ############################################## | |
| usage() { | |
| echo "Usage: $0 [-dh] [-r ref]" | |
| echo ' Options:' | |
| echo ' -d: Debug mode: verbose output, and disable self-removing' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| set -g default-terminal "tmux-256color" | |
| set-option -g prefix C-a | |
| unbind-key C-b | |
| bind-key C-a send-prefix | |
| bind | split-window -h | |
| bind - split-window -v | |
| set-window-option -g mode-keys vi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| set -g default-terminal "tmux-256color" | |
| set-option -g prefix C-a | |
| unbind-key C-b | |
| bind-key C-a send-prefix | |
| bind | split-window -h | |
| bind - split-window -v | |
| set-window-option -g mode-keys vi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #cloud-config | |
| apt_upgrade: True | |
| apt_reboot_if_required: True | |
| apt: | |
| sources: | |
| docker-ce.list: | |
| source: "deb https://download.docker.com/linux/debian buster stable" | |
| keyid: 0EBFCD88 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| apiVersion: kudo.k8s.io/v1alpha1 | |
| kind: PlanExecution | |
| metadata: | |
| labels: | |
| framework-version: mysql-57 | |
| instance: mysql | |
| name: mysql-restore | |
| namespace: default | |
| spec: | |
| instance: |