User Tools

Site Tools


kubernetes_install_on_fedora

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
kubernetes_install_on_fedora [2018/04/09 09:55]
rpjday [cluster/get-kube-binaries.sh]
kubernetes_install_on_fedora [2018/04/09 10:15] (current)
rpjday [cluster/get-kube-binaries.sh]
Line 117: Line 117:
 </​code>​ </​code>​
  
-In short, from the ''​${KUBE_ROOT}''​ directory (and in the context of a 64-bit Fedora system), extract that single ''​kubectl''​ executable::+In short, from the ''​${KUBE_ROOT}''​ directory (and in the context of a 64-bit Fedora system), extract that single ''​kubectl''​ executable:
  
 <​code>​ <​code>​
Line 125: Line 125:
 > -C platforms/​linux/​amd64 > -C platforms/​linux/​amd64
 $ $
 +</​code>​
 +
 +<​code>​
 +$ tree platforms
 +platforms
 +└── linux
 +    └── amd64
 +        └── kubectl
 +$
 +</​code>​
 +
 +Finally, make sure you can find ''​kubectl''​ on your search path somehow:
 +
 +<​code>​
 +PATH=$PATH:/​home/​rpjday/​kubernetes/​dl/​kubernetes/​platforms/​linux/​amd64
 </​code>​ </​code>​
 ===== create_cluster ===== ===== create_cluster =====
 +
 +==== Overview ====
 +
 +This function kicks off a new cluster:
 +
 +<​code>​
 +function create_cluster {
 +  if [[ -n "​${KUBERNETES_SKIP_CREATE_CLUSTER-}"​ ]]; then
 +    exit 0
 +  fi
 +  echo "​Creating a kubernetes on ${KUBERNETES_PROVIDER:​-gce}..."​
 +  (
 +    cd kubernetes
 +    ./​cluster/​kube-up.sh
 +    echo "​Kubernetes binaries at ${PWD}/​cluster/"​
 +    if [[ ":​$PATH:"​ != *":​${PWD}/​cluster:"​* ]]; then
 +      echo "You may want to add this directory to your PATH in \$HOME/​.profile"​
 +    fi
 +
 +    echo "​Installation successful!"​
 +  )
 +}
 +</​code>​
 +
 +You might want to add the ''​cluster/''​ directory to your search path for later:
 +
 +<​code>​
 +PATH=$PATH:/​home/​rpjday/​kubernetes/​dl/​kubernetes/​cluster
 +</​code>​
 +==== create_cluster() ====
 +
 +This function calls the underlying script ''​cluster/​kube-up.sh'':​
 +
 +<​code>​
 +function create_cluster {
 +  if [[ -n "​${KUBERNETES_SKIP_CREATE_CLUSTER-}"​ ]]; then
 +    exit 0
 +  fi
 +  echo "​Creating a kubernetes on ${KUBERNETES_PROVIDER:​-gce}..."​
 +  (
 +    cd kubernetes
 +    ./​cluster/​kube-up.sh
 +    echo "​Kubernetes binaries at ${PWD}/​cluster/"​
 +    if [[ ":​$PATH:"​ != *":​${PWD}/​cluster:"​* ]]; then
 +      echo "You may want to add this directory to your PATH in \$HOME/​.profile"​
 +    fi
 +
 +    echo "​Installation successful!"​
 +  )
 +}
 +</​code>​
kubernetes_install_on_fedora.1523267730.txt.gz · Last modified: 2018/04/09 09:55 by rpjday