Giter Club home page Giter Club logo

iks-intersight-terraform's Introduction

Configuring IKS cluster with Intersight on vSphere Infrastructure

Use Case Statement

Create an IKS 3-node cluster using Terraform Intersight Provider on vSphere Infrastructure registered with Intersight.

Pre-requisites

Please sign up for an account on intersight.com with access to vSphere infrastructure You will need to get the Intersight api and secret key.Also, included in this repo is a terraform.vars file that lists the configuration items to be filled in for the IKS cluster and copied over to terraform.tfvars.

Clone this repository and initialize the provider

The following commands can be used to configure your Terraform environment to use the provider:

git clone https://github.com/prathjan/iks-intersight-terraform.git
cd iks-intersight-terraform
terraform init

Terraform should report "Terraform has been successfully initialized!" following the "terraform init" command.

Configure Variables

  • Copy over terraform.vars to terraform.tfvars.Modify the configuration parameters as needed. The configuration specifies the names of your cluster pools, policies and VM profile that can be modified. You can also change the size of your cluster in the config file.You can also check the Intersight API and reference docs for details on these configuration parameters.
  • Log into intersight.com and get the API keys and SecretKey. Include this in the terraform.tfvars file.
  • Generate ssh keys and include the public key in the vars file as well

IKS Configuration

The main configuration file is cprofile.tf which configures a profile for the k8s cluster, create the master and worker node profile and references the cluster profile and finally deploys the cluster

Validate, Plan and Apply

  • terraform validate
  • terraform plan -out example.tfplan. Review the plan to check out the resources to be provisioned. You should see resources to provision the cluster profile, master/worker node profiles and deploy action for the cluster.
  • terraform apply

Post provisioning steps

Check for successful deployment of cluster in Intersight portal and download kubeconfig for cluster just created. Check for the cluster node list:

  • kubectl --kubeconfig .yml get nodes

Credits

Parts of this README has been taken from https://github.com/CiscoDevNet/intersight-terraform-modules, Credit: David Soper

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.