Three Issues with running KUBERNETES-STIG on a Vanilla EKS build node.
1.) In prelim.yaml, in this particular code
- name: "PRELIM | Get Client version"
ansible.builtin.shell: kubectl version --short | grep "Client Version" | cut -d"v" -f2
changed_when: false
failed_when: false
register: cntrk8stig_kubectl_client_version
The command kubectl version --short is not valid. Should be kubectl version --client
2.) Also kubectl is not installed in a vanilla EKS build. I had to install it prior to hardening.
3.) In addition ths playbook works with the following files, of which none of these exists in an EKS node.
"/etc/kubernetes/manifests/kube-apiserver.yaml"
"/etc/kubernetes/manifests/kube-controller-manager.yaml"
"/etc/kubernetes/manifests/kube-scheduler.yaml"
"/etc/kubernetes/manifests/etcd.yaml"
"/etc/systemd/system/kubelet.service.d/10-kubeadm.conf"
"/var/lib/kubelet/config.yaml"
"/etc/systemd/system/kubelet.service.d/10-kubeadm.conf"
"/var/lib/kube-proxy/config.conf"
"/etc/kubernetes/audit-policy.yaml"
"/etc/kubernetes/pki/apiserver-kubelet-client.crt"
"/etc/srv/kubernetes/pki/root-ca-certificates.crt"
"/etc/kubernetes/pki/apiserver.crt"
"/etc/kubernetes/pki/apiserver.key"
"/etc/kubernetes/admission-control.yaml"
"/etc/kubernetes/audit-policy.yaml"
"/etc/kubernetes/pki/etcd/peer.crt"
"/etc/kubernetes/pki/etcd/peer.key"
Three Issues with running KUBERNETES-STIG on a Vanilla EKS build node.
1.) In prelim.yaml, in this particular code
The command
kubectl version --shortis not valid. Should bekubectl version --client2.) Also kubectl is not installed in a vanilla EKS build. I had to install it prior to hardening.
3.) In addition ths playbook works with the following files, of which none of these exists in an EKS node.