Skip to content

Commit bba95bb

Browse files
wtripp180901sjpb
andauthored
Comment + doc changes from review
Co-authored-by: Steve Brasier <[email protected]>
1 parent 7008500 commit bba95bb

File tree

5 files changed

+5
-2
lines changed

5 files changed

+5
-2
lines changed

ansible/roles/cluster_infra/templates/resources.tf.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ resource "terraform_data" "k3s_token" {
1515
input = "{{ k3s_token }}"
1616
lifecycle {
1717
ignore_changes = [
18-
input,
18+
input, # makes it a write-once value (set via Ansible)
1919
]
2020
}
2121
}

ansible/roles/k3s/tasks/main.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
register: stat_result
77

88
- name: Download and air-gapped installation of k3s
9+
# Using air-gapped install so containers are pre-installed to avoid rate-limiting from registries on cluster startup
910
when: not stat_result.stat.exists
1011
block:
1112

docs/k3s.README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Overview
22
A K3s cluster is deployed with the Slurm cluster. Both an agent and server instance of K3s is installed during image build and the correct service (determined by OpenStack metadata) will be
3-
enabled during boot. Nodes with the `k3s_server` metadata field defined will be configured as K3s agents (this field gives them the address of the server). The Slurm control node is currently configured as a server while all other nodes configured as agents. It should be noted that running multiple K3s servers isn't supported. Currently only the root user on the control node has
3+
enabled during boot. Nodes with the `k3s_server` metadata field defined will be configured as K3s agents (this field gives them the address of the server). The Slurm control node is currently configured as a server while all other nodes are configured as agents. Using multiple K3s servers isn't supported. Currently only the root user on the control node has
44
access to the Kubernetes API. The `k3s` role installs Helm for package management. K9s is also installed in the image and can be used by the root user.
55

66
# Idempotency

environments/.caas/hooks/pre.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
# Generate k3s token
44
- name: Generate k3s token
5+
# NB: Although this generates a new token on each run, the actual token set in metadata is retrieved from a set-once tofu resource, hence only the first value ever generated is relevant.
56
hosts: openstack
67
tasks:
78
- ansible.builtin.set_fact:

environments/common/layouts/everything

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,5 +87,6 @@ cluster
8787
openhpc
8888

8989
[k9s:children]
90+
# Hosts to install k9s on
9091
control
9192

0 commit comments

Comments
 (0)