Moving chown step

This commit is contained in:
vandomej 2025-09-28 18:15:46 -07:00
parent 427047c39c
commit 251f6d305d

View file

@ -77,6 +77,10 @@ resource "null_resource" "talos_cluster" {
--cpus ${self.triggers.vcpu_count} \
--skip-kubeconfig
# Change ownership of the generated files in ~/.talos and ~/.kube
sudo chown -R $(id -u):$(id -g) $HOME/.talos
sudo chown -R $(id -u):$(id -g) $HOME/.kube
# Apply our pre-generated configuration
echo "Applying Talos configuration..."
talosctl apply-config --insecure --nodes 10.5.0.2 --file configs/controlplane.yaml
@ -89,9 +93,6 @@ resource "null_resource" "talos_cluster" {
echo "Generating kubeconfig..."
talosctl --talosconfig configs/talosconfig kubeconfig --nodes 10.5.0.2
# Change ownership of the generated files in ~/.talos and ~/.kube
sudo chown -R $(id -u):$(id -g) $HOME/.talos
sudo chown -R $(id -u):$(id -g) $HOME/.kube
EOT
}