---
apiVersion: v1
kind: Pod
metadata:
  name: pod-centos
  namespace: default
spec: 
  serviceAccountName: basic-access     # We add this line.
  containers:
    - name: cntr-centos
      image: centos
      command: ["/bin/bash", "-c"]
      args:
        - |
          cat <<EOF > /etc/yum.repos.d/kubernetes.repo
          [kubernetes]
          name=Kubernetes
          baseurl=https://packages.cloud.google.com/yum/repos/kubernetes-el7-x86_64
          enabled=1
          gpgcheck=1
          repo_gpgcheck=1
          gpgkey=https://packages.cloud.google.com/yum/doc/yum-key.gpg https://packages.cloud.google.com/yum/doc/rpm-package-key.gpg
          EOF
          yum install -y kubectl
          while true ; do
            date 
            sleep 10 
          done