<commit_before># Kubeup
Simple Kubernetes cluster creator based on
[kubeadm](http://kubernetes.io/docs/admin/kubeadm/) for libvirt (Linux).
Default setup is a single master with three nodes

## Requirements

Install qemu-kvm, libvirt

### Fedora

```
sudo dnf -y install qemu-kvm libvirt
```


### CentOS

* Run the following:

```
sudo yum install epel-release
sudo yum install qemu libvirt qemu-kvm
```

# Usage

## Create global_vars.yml

If you have not already done so, create `global_vars.yml`:

```
$ cp global_vars.yml.tmpl global_vars.yml
```

Edit `global_vars.yml` accordingly, then to create the cluster, type:

```
$ sudo ./up.sh
```

The Kubernetes configuration is then copied from the master node to the host and can be used as follows:

```
$ kubectl --kubeconfig=kubeconfig.conf get nodes
NAME                  STATUS   ROLES    AGE     VERSION
lpabon-k8s-1-master   Ready    master   8m12s   v1.19.5<commit_msg>Update readme to not use sudo with up.sh<commit_after># Kubeup
Simple Kubernetes cluster creator based on
[kubeadm](http://kubernetes.io/docs/admin/kubeadm/) for libvirt (Linux).
Default setup is a single master with three nodes

## Requirements

Install qemu-kvm, libvirt

### Fedora

```
sudo dnf -y install qemu-kvm libvirt
```


### CentOS

* Run the following:

```
sudo yum install epel-release
sudo yum install qemu libvirt qemu-kvm
```

# Usage

## Add your user to libvirt group
```
sudo usermod -a -G libvirt $(whoami)
```

This will allow the *up.sh* script to run without *sudo* later on.

You may also need to restart libvirtd to pick up the change.

```
sudo systemctl restart libvirtd.service
```

## Create global_vars.yml

If you have not already done so, create `global_vars.yml`:

```
$ cp global_vars.yml.tmpl global_vars.yml
```

Edit `global_vars.yml` accordingly, then to create the cluster, type:

```
$ ./up.sh
```

The Kubernetes configuration is then copied from the master node to the host and can be used as follows:

```
$ kubectl --kubeconfig=kubeconfig.conf get nodes
NAME                  STATUS   ROLES    AGE     VERSION
lpabon-k8s-1-master   Ready    master   8m12s   v1.19.5
{'fraction_non_alphanumeric': 0.10275572162540869, 'fraction_numerical': 0.008407286314806165, 'mean_word_length': 3.5671641791044775, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1808063', 'n_tokens_mistral': 770, 'n_tokens_neox': 699, 'n_words': 255}