Skip to content

Instantly share code, notes, and snippets.

@nicoalimin
Last active June 6, 2019 23:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nicoalimin/6b31c8940f4ac3873c63e2fd3f9dbc84 to your computer and use it in GitHub Desktop.
Save nicoalimin/6b31c8940f4ac3873c63e2fd3f9dbc84 to your computer and use it in GitHub Desktop.
Kubernetes-op Help Section

🛠 CTO.ai maintained Kubernetes OP 🚀

A collection of common interactive command line user interfaces to setup and maintain a new kubernetes cluster.

Creating and maintaining a production-grade kubernetes cluster will incur you charges

Commands

All commands start with ops run k8s. From there, you can run the following commands to interact with your AWS-hosted Kubernetes cluster

Things you need to do the following commands successfully:

  • AWS accessKeyId: Can be obtained from the IAM section on your AWS console
  • AWS accessKeySecret: Can be obtained from the IAM section on your AWS console
  • Cluster Name: The name of the cluster you might want to deploy
  • Region: The region you want to deploy the cluster to
  • [Optional] Domain: For private clusters, you would need your own domain and hosted zone
  • [Optional] SSH key pair in your ~/creds folder named cluster_rsa and cluster_rsa.pub for private clusters. For more information, see Generating SSH Key Pair

Create

  • Will create a new kubernetes cluster for in an AWS account for you
  • Takes about ~15 minutes to finish successfully

Destroy

  • Will delete a cluster that has been deployed in an AWS account

Update

  • Allows you to scale the number and instance size of worker nodes in the cluster
  • Takes about ~15 minutes to finish successfully

You would also need:

  • Instance size: The size you want to upgrade the worker node size to
  • Node Count: How many worker nodes you want the cluster to have after the update

Generate-Resources

  • Allows you to deploy you app to the cluster. It can also deploy any docker image.

You would need:

  • A docker image containing your application
  • That image must be exposed at a certain port if you want to make it public

Learning Resources

Below are links that can bootstrap your knowledge on technologies that is a pre-requisite to learn this op

Generating SSH Key Pair

Run the following command mkdir creds && ssh-keygen -b 4096 -t rsa -C "cluster_rsa" -N "" -f ~/creds

Kubernetes

Kops

AWS

Route53


Notes

The Op name would be k8s, instead of kubernetes-ops. Please take note of this when publishing the op, as it would be under k8s.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment