Code Monkey home page Code Monkey logo

kubernetes-the-hard-way's Introduction

Hi there ๐Ÿ‘‹

I'm Xander, and I work on open source at Defense Unicorns.

  • ๐Ÿ˜„ Pronouns: he/him/his
  • ๐Ÿ“ซ How to reach me: @Xander on Kubernetes Slack

kubernetes-the-hard-way's People

Contributors

aberoham avatar adriaandejonge avatar alan01252 avatar amouat avatar andrewpsp avatar dannykansas avatar danquah avatar dpritchett avatar dy-dx avatar elsonrodriguez avatar font avatar gburiola avatar gopi-g-dev avatar hsubramanianaks avatar jessemillar avatar joeint avatar jomagam avatar justinsb avatar kelseyhightower avatar koep avatar ksingh7 avatar lfaoro avatar lisa avatar marcelom avatar markvincze avatar mblair avatar mercer avatar oppegard avatar salaxander avatar senax avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

kubernetes-the-hard-way's Issues

[chapter 03] cannot connect via SSH

After creating the SSH config file, I cannot SSH into the machine because of wrong permissions (working inside WSL in my case):

tomica@N1:~/.ssh$ ssh controller-0
Bad owner or permissions on /home/tomica/.ssh/config

Fix:
chmod 644 ~/.ssh/config

[chapter 04] creating certificates for workers - wrong cuts

It should be cut -f20 and cut -f17 (otherwise you'll get the wrong fields):
EXTERNAL_IP=$(az vm show --show-details -g kubernetes-the-hard-way -n ${instance} --output tsv | cut -f20)
INTERNAL_IP=$(az vm show --show-details -g kubernetes-the-hard-way -n ${instance} --output tsv | cut -f17)

[chapter 04] missing EOF in The Controller Manager Client Certificate

Missing the EOF in The Controller Manager Client Certificate:
cat > kube-controller-manager-csr.json <<EOF
{
"CN": "system:kube-controller-manager",
"key": {
"algo": "rsa",
"size": 2048
},
"names": [
{
"C": "US",
"L": "Portland",
"O": "system:kube-controller-manager",
"OU": "Kubernetes The Hard Way",
"ST": "Oregon"
}
]
}
EOF

[chapter 13] Cannot curl exposed service

In the smoke test chapter, we expose an nginx service, and try to curl the node port on a worker node using

curl -I http://${EXTERNAL_IP}:${NODE_PORT}

This is failing for me still. I'm thinking it may be something with the security group rule as I'm getting a connection refused.
Any help troubleshooting this would be appreciated!

Setup SSH config for accessing VMs

Since the Azure CLI can't SSH to nodes without a public IP like the Google Cloud CLI, this tutorial contains a lot of lines like this:

EXTERNAL_IP=$(az vm show --show-details -g kubernetes-the-hard-way -n controller-0 --output tsv | cut -f19)
ssh azureuser@${EXTERNAL_IP}

Let's add a step to build an SSH config so that all the following steps become more like:

ssh azureuser@worker-0

[Chapter 03] Default Limit of vCPUs on Azure is 10. 12 Needed for Chapter.

Issue

The default limit of vCPUs in a region is 10. This chapter requires 12 to be created. This causes the creation of worker-2 to fail.

image

If the user submits the request to create this worker within the iterated series. The request will fail silently. If the user submits the request to create the worker independently, they will receive the following error:

Azure Error: InvalidTemplateDeployment
Message: The template deployment 'vm_deploy_5rAXEbqdNbfTEgfZ0S4u5i6R2SMKCvJO' is not valid according to the validation procedure. The tracking id is 'XXXXXXXXXXXXXXXXXXXX'. See inner errors for details. Please see https://aka.ms/arm-deploy for usage details.
Exception Details:
        Error Code: QuotaExceeded
        Message: Operation results in exceeding quota limits of Core. Maximum allowed: 10, Current in use: 10, Additional requested: 2. Please read more about quota increase at https://aka.ms/ProdportalCRP/?#create/Microsoft.Support/Parameters/{"subId":"XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX","pesId":"XXXXX","supportTopicId":"32447243"}.

Possible Solution

Increasing the limit is not exceptionally difficult, but does require submitting a support ticket and knowing how to interpret the error above correctly. It may be helpful to have a note in the section on creating workers that describes this potential issue and how to fix it.

[chapter 03] creating the config file for SSH - wrong indentation

Should be (EOF should be pulled out, in the same column with "done"; if not, shell waits for additional input):
for instance in controller-0 controller-1 controller-2 worker-0 worker-1 worker-2; do
EXTERNAL_IP=$(az vm show --show-details -g kubernetes-the-hard-way -n ${instance} --output tsv | cut -f20)
cat <<EOF | tee -a ~/.ssh/config
Host ${instance}
User azureuser
HostName ${EXTERNAL_IP}
IdentityFile ~/.ssh/id_rsa
ServerAliveInterval 120
EOF
done

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.