Skip to content

Latest commit

 

History

History
292 lines (214 loc) · 13.1 KB

README.md

File metadata and controls

292 lines (214 loc) · 13.1 KB

VM Image Builder Scripts

https://github.com/simula/nornet-vmimage-builder-scripts

Table of Contents

Introduction

This repository contains Virtual Machine (VM) image building scripts, to automatically generate freshly installed VM images for different projects and purposes, like minimal servers, basic console setups, development environments, as well as full desktop machines. The scripts use Packer (https://www.packer.io).

As part of the VM setup process, it is also possible to set custom bootsplashes and desktop/screen locker/login background images for customisation.

Requirements

To start a VM build, run one the the "make" scripts:

./make-<PROJECT>

with e.g. "minimal", "basic", "development", "kde", "kde+development", "hipercontracer", etc.!

See further details about the different VM hypervisor variants, systems, and projcts (choice of packages to install) below!

Hypervisors

VirtualBox

The VirtualBox images use optimised settings for display, network and storage. Two disk layouts are available: 3-disks (separate disks for /, /home, and swap) and 1-disk (one disk for everything).

Proxmox

VMs for usage in Proxmox. They are basically like the VirtualBox variant, with the QEMU Guest Agent installed.

QEMU

The QEMU images use optimised settings for display, network and storage. Two disk layouts are available: 3-disks (separate disks for /, /home, and swap) and 1-disk (one disk for everything). These images are mainly useful for OpenStack, for which the layout should be 1-disk.

vSphere

VMs for usage in vSphere. They are basically like the VirtualBox variant, with the Open VM Tools installed.

Docker

Containers for usage in Docker.

Systems

The following operating systems are currently supported as VM guests:

Details can be found in the directories installer and http.

Ubuntu Linux

General settings:

Debian Linux

General settings:

  • Base: Debian Netinstall ISO
  • EFI boot
  • Using BTRFS for / and /home, with subvolumes @ and @home

Fedora Core Linux

General settings:

FreeBSD

General settings:

  • Base: FreeBSD installation ISO
  • EFI boot
  • Using ZFS for / and /home

Projects

Details can be found in the directory projects.

Minimal

The minimal installation for the system with the settings described above. This project is meant mainly for testing purposes. In most cases, you want the Basic project instead!

Provided packages:

  • Bash (shell)
  • cURL (download tool)
  • Git (revision management)
  • GnuPG (cryptography for signature checks)
  • Ping (network connectivity check)
  • Sudo (privileged command execution)
  • Virt-What (identification of virtualisation environment)

Further properties:

  • /etc/os-release with operating system information exists
  • Bash as default shell
  • Explicit Congestion Notification (ECN, RFC 3168) enabled
  • Stream Control Transmission Protocol (SCTP, RFC 4960) enabled
  • SSH server enabled
  • Hardened SSH server and client settings (weak algorithms disabled)
  • UTF-8 character encoding
  • Enabled automatic installation of updates

Basic

The "Basic" installation is based on the Minimal installation.

It must contain the following packages:

  • Base64 (base64 tool)
  • BIND Tools (DNS testing, particularly dig and delv commands)
  • BWM-NG (simple bandwidth monitor)
  • BZip2 (compression tool)
  • EthTool (Ethernet card configuration tool; on Linux systems only!)
  • Fail2Ban (prevent brute-force SSH attacks)
  • GDisk (GPT partitioning tool)
  • GrowPart (Partition growing tool; on Linux systems only!)
  • IDN (Internationalised Domain Names command line tool)
  • GNU Parallel (Parallel job execution)
  • GNU Wget (download tool)
  • HiPerConTracer (high-performance network tracing tool)
  • HTop (process monitor)
  • Joe (editor)
  • JQ (JSON editing tool)
  • NMap (network testing tool)
  • Manual page utilities (manual page viewer)
  • NetPerfMeter (network performance metering tool)
  • NetPlan (network configuration; on Linux systems only!)
  • OpenSSL (Cryptography and TLS toolkit)
  • Ping, Traceroute, ifconfig (basic networking tools)
  • PLocate ("locate" command for finding files)
  • PwGen (password generator)
  • Python (Python 3 interpreter)
  • RSPLIB RSerPool Tools (RSerPool testing tools)
  • RSync Tools (file synchronisation)
  • SubNetCalc (address calculator)
  • System-Tools (system information on login)
  • Tree (tree view of directory hierachy)
  • T-Shark (packet sniffer, CLI-version for Wireshark)
  • UUID (UUID generator)

KDE

The "KDE" installation is based on the Basic installation.

It must contain the following packages:

Further properties:

  • Configured KDE and SDDM login manager
  • Configured 4 virtual desktops
  • Configured switchable keyboard layouts
  • Configured Konsole keyboard shortcuts
  • Configured Firefox (hardened settings, enhanced privacy settings, as well as some add-ons like NoScript, uBlock Origin, etc.)
  • Configured Wireshark (predefined filters, coloring rules, etc.)
  • Ubuntu 22.04+: Firefox is installed from PPA mozillateam/ppa (https://launchpad.net/~mozillateam/+archive/ubuntu/ppa/+packages), instead of using the Snap package.

Development

The "Development" installation is based on the Basic installation.

It must contain the following packages:

It must contain the following libraries and development files:

Further properties:

  • Password-less sudo calls. ⚠WARNING: Development settings are intended for developers only!
  • Wireshark as regular user is allowed. ⚠WARNING: Development settings are intended for developers only!
  • Source packages enabled from package manager (if available)

KDE+Development

The "KDE+Development" installation is based on the KDE and Development installation.

Further Projects

NorNet

Basic for general-purpose server usage, particularly for working with NorNet purposes.

NorNet-Desktop

Basic NorNet VMs for general-purpose desktop usage. They base on the NorNet images, with additional KDE desktop.

NEAT

Basic for general-purpose desktop usage, particularly for working with NEAT. They base on the NorNet-Desktop images, with NEAT packages and build environment.

Features:

  • NEAT installed (NEAT library as well as NEAT sockets API library).
  • Source repositories cloned under ~/src. Build dependencies are already installed.

RSerPoolDemo

Basic for general-purpose desktop usage, particularly for working with RSerPool, based on the KDE+Development installation.

Features:

  • RSPLIB installed.
  • RSerPoolDemo-Tool installed.
  • Source repositories cloned under ~/src. Build dependencies are already installed.

SimulaMet-Desktop

These are SimulaMet desktop VMs, based on the KDE+Development installation.

Features:

  • Some SimulaMet-related source repositories cloned under ~/src.

5gVINNI

Basic for general-purpose desktop usage, particularly for working with 5gVINNI. They base on the NorNet images.