Skip to main content

Server Installation

BeetleboxCI server is an on-premises CI solution for customers who have large scale computational needs for their CI applications. BeetleboxCI is capable on running on bare metal or on a virtual machine, it operates on an on-premises Kubernetes cluster.

Mininum requirements for installing BeetleboxCI::

  • An x64/x86_64/AMD64/Intel 64 system
  • At least 4 CPUs
  • At least 16GB RAM

Recommended:

  • An x64/x86_64/AMD64/Intel 64 system
  • At least 12 CPUs
  • At least 32GB RAM

Introduction

BeetleboxCI exposes a number of services:

Frontend web application accessed through a browser. (Port 32767)

A local container registry to store images to run jobs. (Port 5000)

An NFS server to allow other nodes to access shared files (Port 2049)

The application exposes a number of ports:

32767 - TCP - Web app traffic

443 - TCP - Metrics server

5432 - TCP - Postgresql

6379 - TCP - Redis

179 - TCP - Calico CNI

2049 - TCP - NFS

BeetleboxCI uses kubernetes to schedule user-defined jobs

Services

beetleboxci-db beetleboxci-redis-server beetleboxci-redis-worker beetleboxci-redis-scheduler - handles cron jobs beetleboxci-nginx beetleboxci-web metrics-server registry

Platform

BeetleboxCI is designed to be deployed onto an on-premises Kubernetes cluster. It may work on self-managed cloud instances too, but it has not been extensively tested for this purpose.

Scripted Installation

BeetleboxCI provides a set of scripts through which you can install the application on a server from scratch if your server is running Ubuntu Server 22.04.1. These scripts set up kubernetes for you as well as installing BeetleboxCI using a helm chart.

It is likely that many server setups will require manual installation.

You can download the latest version of the server installer from https://userportal.beetleboxci.com/download/latest.

Installing BeetleboxCI

Before you begin, please ensure that you know the hostname, fully qualified domain name (FQDN) and IP address of each of the servers that will form the cluster.

On a Linux machine:

  • Hostname: The hostname can be obtained by typing the command hostname into a Linux terminal.
  • Fully Qualified Domain Name: The fully qualified domain name would be managed by the network administrator in your organisation if the server is part of a company intranet. It may be of a similar form to hostname.companyname.com. For machines not on a network domain, the FQDN would usually be hostname.local.
  • IP Address: The IP address can be obtained by typing ifconfig into a terminal or by running hostname -I | awk '{print $1}', which will usually list several network adapters. The IP address to use is the one that corresponds to the main network interface (Ethernet/WiFi) of your server.
  1. Extract the tarball using a terminal and enter the folder that gets extracted:

    tar -xzvf BeetleboxCIv*.tar.gz
    cd dist/BeetleboxCIv*
  2. Open the 000_params_example.sh parameter file and edit the following parameters:

    BeetleboxCI application parameters:

    ParameterDescription
    CONTROL_NODE_FQDNFully qualified domain name of the server where the BeetleboxCI application is installed
    BBX_DEPLOY_NODEHostname of the server where the BeetleboxCI application is installed
    BBX_DEPLOY_NODE_IPIP address of the server where the BeetleboxCI application is installed

    Network File System (NFS) parameters:

    ParameterDescription
    NFS_SERVER_FQDNFully qualified domain name of the server where the NFS is located
    NFS_SERVER_NAMEHostname of the server where the NFS is located
    NFS_SERVER_IPIP address of the server where the NFS is located
    NFS_SERVEROn multi-node clusters, we recommend setting this to the same value as the NFS_SERVER_FQDN. On single node clusters, this can be set to the IP of the server if the IP is static or otherwise set to the same value as NFS_SERVER_FQDN or NFS_SERVER_NAME.

    Container Registry parameters:

    ParameterDescription
    REGISTRY_FQDNFully qualified domain name of the server where the container registry is hosted
    REGISTRY_NODE_NAMEHostname of the server where the container registry is hosted
    REGISTRY_IPIP address of the server where the container registry is hosted
    REGISTRY_URLOn multi-node clusters, we recommend setting this to the same value as the REGISTRY_FQDN. On single node clusters, this can be set to the IP of the server if the IP is static or otherwise set to the same value as REGISTRY_FQDN or REGISTRY_NODE_NAME.

    If you are only using a single node cluster, then the BeetleboxCI application, the NFS and the Container Registry will share the same parameter values.

  3. Run the 00_init_control_node.sh script. You will be prompted for the path of the parameter file which you edited earlier. This script installs the Kubernetes software and sets up a cluster on your machine.

    ./00_init_control_node.sh
  4. Now you can restart your machine. Restarting is required for the containerisation backend to function correctly, otherwise the following scripts will not work correctly.

  1. Run the following command to check that all the modules are running correctly — they may take a few minutes to stabilise, so you may need to run this command again:

    kubectl get po --all-namespaces
  2. Run the 10_install_nfs.sh script. This installs the software needed for a network file system to run on the machine.

    ./10_install_nfs.sh
  3. Run the 11_create_nfs.sh script. You will be prompted to enter the path of the parameter file again. This sets up a network file system on your machine to allow communication between containers in BeetleboxCI.

    ./11_create_nfs.sh
  4. Run the 40_create_certs. script. You will be prompted to enter the path of the parameter file. This creates the SSL certificates needed to set up the local container registry.

    ./40_create_certs.sh
  5. Run the 41_create_registry.sh script. You will be prompted to enter the path of the parameter file.

    ./41_create_registry.sh
  6. Run the 60_install_app.sh script. This builds and starts the BeetleboxCI application on the Kubernetes cluster.

    ./60_install_app.sh
  1. To access the application within the (virtual) machine where you installed BeetleboxCI, open a web browser and navigate to http://127.0.0.1:32767. If you need to access the BeetleboxCI web application from another machine (on the same local network) other than the control plane node, then you will need to replace 127.0.0.1 with the IP address or hostname of the control plane node.

  2. If you are accessing the app for the first time, you will be prompted to create a superuser account. You can log in once you create the superuser account.

Upgrading BeetleboxCI

The tarball contains a script (60_install_app.sh) that can be used to upgrade to a newer version, and the steps to upgrade are below:

  1. Extract the tarball using a terminal and enter the folder that gets extracted:

    tar -xzvf BeetleboxCIv*.tar.gz
    cd BeetleboxCIv*
  2. Run the 60_install_app.sh script with the -u flag. This indicates that an update is being installed.

    ./60_install_app.sh -u
  3. Run the following command to check that all the modules are running correctly — they may take a few minutes to stabilise, so you may need to run this command again:

    kubectl get po --all-namespaces
  4. You are now ready to use the latest version of BeetleboxCI.

Manual Installation

In some cases, you may already have a server with Kubernetes installed on it, and in other cases, the exact dependencies required by the automated scripts may not be available.

Create Kubernetes Cluster

For the time being, BeetleboxCI has been tested exclusively on single-node Kubernetes clusters and it is mandatory for worker nodes to exist on the cluster.

BeetleboxCI currently supports Kubernetes 1.28-1.30.

Install BeetleboxCI packages using Helm

Once you have Kubernetes up and running, you can deploy BeetleboxCI onto the cluster.