Giter Club home page Giter Club logo

60sk3s's Introduction

Proof

60sk3s

Kubernetes in 60 seconds deployer. Simple bash script which spins up VMs in GCP/DigitalOcean, installs k3s on them and downloads kubeconfig.

Getting Started

Please follow the instructions below depending on the cloud provider you want to use.

DigitalOcean

Prerequisites

For DigitalOcean, the only thing you need is token (How to get token) and ssh key fingerprints. DO cli is not required. Simply paste your token on line 7:

# Paste your DO token below
do_api_token=""

And ssh key fingerprint (you can get it from the "Security" menu on your digitalocean account) in both JSON files in digitalocean folder. Feel free to change droplet size, region, whatever according to your needs.

"ssh_keys": ["8b:f9:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx"],

Usage

If you wish not to overwrite your existing kubeconfig (which script does by default), set load_kube_config to false (line 9 in k3s_deployer.sh)

Simply execute

./k3s_deployer.sh

On DigitalOcean process takes around 2 minutes.

Google Cloud

Prerequisites

In order to use 60sk3s with Google Cloud, you need to have gcloud CLI installed (How to do it) and preferably default zone and project set. You can do that by executing:

gcloud auth login
gcloud config set compute/region europe-west4-a

gcloud config set core/project my-project

It also assumes that you have your ssh key added to project metadata (therefore it's loaded into every VM you spins up in that project). If you don't, then you can either do that (How-to) or provide you ssh key in the script itself. For that, you need to uncomment and fill lines 43 and 54 in GCP/deploy.sh

Just keep in mind that You need to put it in format username:your_ssh_key. So if You do $cat your_id_rsa.pub at the end there will be something like john@host, so then your metadata parameter should look like:

--metadata=ssh-keys="john:ssh-rsa AAAAB3Nz[...]ktk/HB3 john@host" \

Usage

Execute:

./deployer.sh [cluster_name]

To destroy the cluster:

./deployer.sh [cluster_name] delete

On GoogleCloud process takes less than 60 seconds.

Contributing

Simply raise a GitHub issue or send a PR.

License

This project is licensed under the GPL-3.0 license - see the LICENSE.md file for details

60sk3s's People

Contributors

davidzisky avatar walidshaari 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.