iknite

command module
v0.1.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 1, 2022 License: Apache-2.0 Imports: 1 Imported by: 0

README

Go Version Contributors Forks Stargazers Issues Apache 2.0 License Experimental LinkedIn Workflow


Logo

Iknite

Manages the initialization and start of a Kubernetes mono-machine cluster on Alpine Linux.
Explore the docs »

Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. Roadmap
  5. Contributing
  6. License
  7. Contact
  8. Acknowledgments

About The Project

Iknite manages the initialization and start of a Kubernetes cluster in an Alpine based WSL 2 distribution or VM.

Iknite is part of the kaweezle project. Kaweezle allows running a Kubernetes cluster on Windows using Windows Subsystem for Linux 2 (WSL 2).

It is a small go based executable. It can be run from the command line or as an openrc based service.

It is packaged as an APK that is used by the kaweelze-rootfs project.

(back to top)

Built With

This project uses the following components:

(back to top)

Getting Started

Please refer to the kaweezle readme for installation instructions.

The follwing sections give instuctions on how to use the root filesystem without the kaweezle windows command.

Prerequisites

To run kaweezle, you'll need to have WSL installed.

The simplest way to install it is to run the following command:

> wsl --install

After reboot, update the kernel and set the default version to version 2:

> sudo wsl --update
> wsl --set-default-version 2

For the other tools, you can use Scoop.

To use the kubernetes cluster, you will need to have kubectl installed:

> scoop install kubectl

Other tools might be of insterest, like k9s, kubectx, kubens or stern. All are available through scoop. You can install all of them at once with the following command:

> scoop install k9s kubectx kubens stern

Download and installation

The root filesystem can be downloaded from the Releases page.

You can create a WSL distribution with the following set of commands:

> cd $env:LocalAppData
> mkdir kwsl
> cd kwsl
> (New-Object Net.WebClient).DownloadFile("https://github.com/kaweezle/kaweezle-rootfs/releases/download/latest/rootfs.tar.gz", "$PWD\rootfs.tar.gz")
> wsl --import kwsl .

You will have a WSL distribution called kwsl which file system will be located in the current director:

❯ wsl -l -v
  NAME                    STATE           VERSION
* Alpine                  Stopped         2
  kwsl                    Stopped         2

(back to top)

Usage

To start the kubernetes cluster, issue the following command:

❯ wsl -d kwsl /sbin/iknite start

The distribution is now running:

❯ wsl -l -v
  NAME                    STATE           VERSION
* Alpine                  Stopped         2
  kwsl                    Running         2

Now the kubernetes cluster can be accessed:

❯ $env:KUBECONFIG="\\wsl$\kwsl\root\.kube\config"
❯ kubectl get nodes
NAME              STATUS   ROLES    AGE   VERSION
laptop-vkhdd5jr   Ready    <none>   61s   v1.23.1
❯ kubectl get pod --all-namespaces
NAMESPACE            NAME                                      READY   STATUS    RESTARTS   AGE
kube-system          coredns-64897985d-bhhzq                   1/1     Running   0          68s
kube-system          coredns-64897985d-mvpbb                   1/1     Running   0          68s
kube-system          etcd-laptop-vkhdd5jr                      1/1     Running   0          84s
kube-system          kube-apiserver-laptop-vkhdd5jr            1/1     Running   0          84s
kube-system          kube-controller-manager-laptop-vkhdd5jr   1/1     Running   0          84s
kube-system          kube-flannel-ds-hkz9p                     1/1     Running   0          68s
kube-system          kube-proxy-xx5xp                          1/1     Running   0          68s
kube-system          kube-scheduler-laptop-vkhdd5jr            1/1     Running   0          78s
kube-system          metrics-server-d9c898cdf-7qbbr            1/1     Running   0          68s
local-path-storage   local-path-provisioner-566b877b9c-qnpzx   1/1     Running   0          68s
metallb-system       controller-7cf77c64fb-h72jx               1/1     Running   0          68s
metallb-system       speaker-2h66l                             1/1     Running   0          68s

(back to top)

Roadmap

  • Automate the releases through Github actions.
  • ...

See the open issues for a full list of proposed features (and known issues).

(back to top)

Contributing

Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)

License

Distributed under the Apache License. See LICENSE for more information.

(back to top)

Contact

Kaweezle - @kaweezle

Project Link: https://github.com/kaweezle/iknite

(back to top)

Acknowledgements

This project started from the amazing work made by yuk7 with wsldl and AlpineWSL.

It also uses the great work made by the Alpine Linux community on the edge repository.

You may be interested by existing alternatives from which we have taken some ideas:

By using kubeadm and Alpine, kaweezle is closer to the clusters you may use on public clouds.

This readme has has been created from the Best-README-Template project.

(back to top)

Documentation

Overview

Copyright © 2021 Antoine Martin <antoine@openance.com>

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Directories

Path Synopsis
pkg
k8s

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL