GithubHelp home page GithubHelp logo

potiuk / setup-kind Goto Github PK

View Code? Open in Web Editor NEW

This project forked from engineerd/setup-kind

0.0 2.0 0.0 639 KB

kind (Kubernetes in Docker) GitHub Action

License: MIT License

TypeScript 100.00%

setup-kind's Introduction

@engineerd/setup-kind

Setup KinD (Kubernetes in Docker) with a single GitHub Action!

This action assumes a Linux environment, and will not work on Windows or MacOS agents.

name: "Create cluster using KinD"
on: [pull_request, push]

jobs:
  kind:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@master
    - uses: engineerd/[email protected]
    - name: Testing
      run: |
        kubectl cluster-info
        kubectl get pods -n kube-system
        echo "current-context:" $(kubectl config current-context)
        echo "environment-kubeconfig:" ${KUBECONFIG}

Note: KUBECONFIG is automatically merged after cluster creation starting with version 0.6 of Kind. See this document for a detailed migration guide

Note: GitHub Actions workers come pre-configured with kubectl.

The following arguments can be configured on the job using the with keyword (see example above). Currently, possible inputs are all the flags for kind cluster create, with the additional version, which sets the Kind version to downloadm and skipClusterCreation, which when present, skips creating the cluster (the Kind tools is configured in the path).

Optional inputs:

  • version: version of Kind to use (default "v0.7.0")
  • config: path (relative to the root of the repository) to a kind config file. If omitted, a default 1-node cluster will be created
  • image: node Docker image to use for booting the cluster.
  • name: cluster context name (default "kind-kind")
  • wait: wait for control plane node to be ready (default "300s")
  • skipClusterCreation: if "true", the action will not create a cluster, just acquire the tools

Example using optional inputs:

name: "Create cluster using KinD"
on: [pull_request, push]

jobs:
  kind:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@master
    - uses: engineerd/[email protected]
      with:
          version: "v0.7.0"
    - name: Testing
      run: |
        kubectl cluster-info
        kubectl get pods -n kube-system
        echo "current-context:" $(kubectl config current-context)
        echo "environment-kubeconfig:" ${KUBECONFIG}

setup-kind's People

Contributors

superbrothers avatar aisuko avatar radu-matei avatar

Watchers

James Cloos avatar  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.