All Projects → bakins → Kubernetes Coreos Terraform

bakins / Kubernetes Coreos Terraform

Licence: mit
Simple Kubernetes cluster on CoreOS in AWS using Terraform

Labels

Projects that are alternatives of or similar to Kubernetes Coreos Terraform

Hcledit
A command line editor for HCL
Stars: ✭ 104 (-8.77%)
Mutual labels:  hcl
Terraform Google Vault
A Terraform Module for how to run Vault on Google Cloud using Terraform and Packer
Stars: ✭ 108 (-5.26%)
Mutual labels:  hcl
Awesome Codepipeline Ci
an AWS CodePipeline, AWS CodeBuild, AWS APIGateway & AWS Lambda CI
Stars: ✭ 112 (-1.75%)
Mutual labels:  hcl
Spinnaker Terraform
A set of terraform scripts to create an environment from scratch with a Bastion Host, Jenkins, and Spinnaker
Stars: ✭ 106 (-7.02%)
Mutual labels:  hcl
Aws Ecs Airflow
Run Airflow in AWS ECS(Elastic Container Service) using Fargate tasks
Stars: ✭ 107 (-6.14%)
Mutual labels:  hcl
Terraform Aws Ecr
Terraform Module to manage Docker Container Registries on AWS ECR
Stars: ✭ 110 (-3.51%)
Mutual labels:  hcl
Aws Minikube
Single node Kubernetes instance implemented using Terraform and kubeadm
Stars: ✭ 101 (-11.4%)
Mutual labels:  hcl
Terraform Null Ansible
Terraform Module to run ansible playbooks
Stars: ✭ 114 (+0%)
Mutual labels:  hcl
Terraform Aws Config
Enables AWS Config and adds managed config rules with good defaults.
Stars: ✭ 107 (-6.14%)
Mutual labels:  hcl
Aws Lambda Es Cleanup
AWS Elasticsearch Lambda Curator
Stars: ✭ 112 (-1.75%)
Mutual labels:  hcl
Libvirt K8s Provisioner
Automate your k8s installation
Stars: ✭ 106 (-7.02%)
Mutual labels:  hcl
Aws Accounts Terraform
Stars: ✭ 108 (-5.26%)
Mutual labels:  hcl
Terraform Config
Terraform bits and bytes
Stars: ✭ 111 (-2.63%)
Mutual labels:  hcl
Terraform Aws Dynamic Subnets
Terraform module for public and private subnets provisioning in existing VPC
Stars: ✭ 106 (-7.02%)
Mutual labels:  hcl
Best Practices
No description, website, or topics provided.
Stars: ✭ 1,478 (+1196.49%)
Mutual labels:  hcl
Typhoon
Minimal and free Kubernetes distribution with Terraform
Stars: ✭ 1,397 (+1125.44%)
Mutual labels:  hcl
Terraform Aws Vpc
An example of Terraform which brings up a VPC with Public/Private Subnets
Stars: ✭ 109 (-4.39%)
Mutual labels:  hcl
Hello Lambda
🔥 An example of a Python (AWS) Lambda exposed with API Gateway, configured with Terraform.
Stars: ✭ 114 (+0%)
Mutual labels:  hcl
Terraform aws scp
AWS Organizations Service Control Policies (SCPs) written in HashiCorp Terraform.
Stars: ✭ 114 (+0%)
Mutual labels:  hcl
Terraform Up And Running Code
Code samples for the book "Terraform: Up & Running" by Yevgeniy Brikman
Stars: ✭ 1,739 (+1425.44%)
Mutual labels:  hcl

Kubernetes on CoreOS in AWS using Terraform

Provision a Kubernetes cluster with Terraform on AWS.

Inspired by kubestack

Status

This is no longer maintained. All the versions are old. Feel free to use this to inspire you.

Prep

Terraform

Terraform will be used to declare and provision a Kubernetes cluster.

Prep

Create a terraform.tfvars file in the top-level directory of the repo with content like:

ssh_key_name = name_of_my_key_pair_in_AWS
access_key = my_AWS_access_key
secret_key = my_AWS_secret_key

This file is ignored by git. You can also set these by using environment variables.

You also need to make sure you are running ssh-agent and have your AWS key added.

Usage

This repo includes a very simple Makefile that will handle generating an etcd discovery token.

To create the cluster, run make apply

To destroy the cluster, run make destroy

You can override any variables listed in variables.tf such as the ami to use, number of nodes, etc

Next Steps

When you create a cluster, it will output something like:

Outputs:
  kubernetes-api-server =
# Use these commands to configure kubectl
kubectl config set-cluster testing --insecure-skip-tls-verify=true --server=IP
kubectl config set-credentials admin --token='4c98e411'
kubectl config set-context testing --cluster= testing --user=admin
kubectl config use-context testing

Run these commands to configure kubectl. You can see these commands again by running terraform output kubernetes-api-server

Test this by running kubectl get nodes

You should now be able to use kubectl to create services. See the kubernetes examples to get started.

TODO

Differences from kubestack

Most of the differences are based on my personal opionions and/or just trying a different approach.

  • We use base CoreOS image and install Kubernetes at boot time. This was originally to skip the "build image, upload, test, repeat" cycle during development, but it does expose the install process more clearly.
  • We use etcd in proxy mode on the master and workers rather than pointing directly to etcd servers.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].