Skip to content

riasc-ansible contains a set of Ansible roles and playbooks to provision RIasC nodes

License

Notifications You must be signed in to change notification settings

ERIGrid2/riasc-ansible

Repository files navigation

RIasC Ansible Playbooks

DOI GitHub Lint

Introduction

This repository container a set of Ansible roles and playbooks to provision RIasC nodes.

Specifically it contains roles for provisioning a k3s Kubernetes cluster on a fleet of Raspberry Pi nodes. In addition it prepares the nodes by installing the Wireguard VPN kernel module and a devicetree overlay required for GPS-based time-synchronization. At last it installs the RIasC Helm chart.

These playbooks are usually used by the riasc-update.sh script from the riasc-provisioning repo.

Currently, the repo also contains the Ansible inventory for the RIasC deployment used in the ERIGrid 2.0 project. However, it its planned to move this inventory to a separate repo.

Documentation

For further documentation, please consult: https://riasc.eu/docs/

K3s Ansible Playbook

Build a Kubernetes cluster using Ansible with k3s. The goal is easily install a Kubernetes cluster on machines running:

  • Debian
  • Ubuntu
  • CentOS

on processor architecture:

  • x64
  • arm64
  • armhf

System requirements

Deployment environment must have Ansible 2.4.0+ Master and nodes must have passwordless SSH access

Usage

First create a new directory based on the sample directory within the inventory directory:

cp -R inventory/sample inventory/my-cluster

Second, edit inventory/my-cluster/hosts.ini to match the system information gathered above. For example:

[master]
192.16.35.12

[node]
192.16.35.[10:11]

[cluster:children]
master
node

If needed, you can also edit inventory/my-cluster/group_vars/all.yml to match your environment.

Start provisioning of the cluster using the following command:

ansible-playbook site.yml -i inventory/my-cluster/hosts.ini

Kubeconfig

To get access to your Kubernetes cluster just

scp debian@master_ip:~/.kube/config ~/.kube/config

Credits

Funding acknowledgement

European Flag The development of RIasC has been supported by the ERIGrid 2.0 project of the H2020 Programme under Grant Agreement No. 870620