Code Monkey home page Code Monkey logo

kh8s-test-gcp's Introduction

k8s-gcp-terraform

Kubernetes on Google Cloud Platform in Google Kubernetes Engine with Terraform.

GCP

The following setup assumes you have already a Google Profile created.

  1. As the first step, go to the Google Cloud Platform Console and sign in or, if you don't already have an account, sign up.
  2. Then, create a new Billing Account.
  3. Finally create a new project.

CLI

To interact with the Google Cloud Platform you will use gcloud CLI which is a part of the Google Cloud SDK. You must download and install the SDK on your system and initialize it before you can use the gcloud command-line tool:

brew tap caskroom/cask
brew cask install google-cloud-sdk

Use the following command to perform several common SDK setup tasks. These include authorizing the SDK tools to access Google Cloud Platform using your user account credentials and setting up the default SDK configuration.

gcloud init

Finally, once you've gone through the entire setup, run the initialization script to configure Google Cloud itself:

Keep in mind to fill the following variables there: TF_BILLING_ACCOUNT_ID and TF_FOLDER.

./init.sh

Terraform

To use your own user credentials for Terraform when interacting with Google Cloud, run:

gcloud auth application-default login

In your browser, log in to your Google user account when prompted and click Allow to grant permission to access Google Cloud Platform resources.

Your credentials will be stored in ~/.config/gcloud/application_default_credentials.json and used with Terraform to authorize.

Usage

Firstly, to initialize Terraform and install all required plugins, you should do:

terraform init -upgrade

Then, to compare the remote state with the required changes, run:

terraform plan

Finally, to promote the local changes onto the current setup, execute:

terraform apply

kh8s-test-gcp's People

Contributors

kamillelonek avatar

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.