RMU Build: MaaS Setup
Provision the MaaS (Metal as a Service) container on the Gen-1.5 RMU, install MaaS, share it via Teleport, perform the initial configuration, and reserve a DHCP range for BMCs.
This page covers section IV of the Gen-1 to Gen-1.5 RMU build runbook. MaaS (Metal as a Service) provides DHCP/DNS and device discovery on the management network.
Complete the Teleport setup before starting.
A. Create Proxmox CT
-
From the main Proxmox page, click Create CT to open the Create: LXC Container dialog.
-
Tick Advanced and configure:
- CT ID:
120 - Hostname:
<dc>-maas - Set a non-trivial password for
rootand store it in your password manager asMaaS {ICR}. Optionally add your SSH public key.
Click Next.
- CT ID:
-
Select the
ubuntu-22.04-standardtemplate. Click Next. -
Set the disk size to
30GB. Click Next. -
Set Cores to
8. Click Next. -
Set Memory and Swap to
4096. Click Next. -
Configure the network:
- Bridge:
vmbr1(LAN) - Uncheck Firewall.
- IPv4:
Static, IP10.10.100.20/24(CIDR is required) - Gateway:
10.10.100.1 - IPv6:
SLAAC
Click Next.
- Bridge:
-
No changes are required on the DNS tab. Click Next.
-
Tick Start after created and click Finish.
-
When complete, close the dialog window.
-
Ensure Proxmox is configured to start the VM at boot. Select the VM in the left navigation, click Options, double-click Start at Boot, tick the box, and click OK.
B. Install MaaS software via APT
-
Open the console: RMU > 120 (maas) > Console. Update the server software:
apt update && apt upgrade -y reboot -
Add a generic admin account. Replace
<admin>with your admin username — this account will be used to log in to the MaaS web GUI:useradd -u1000 -U -m -c "Admin" -s /bin/bash <admin> -
Install software tools (so that
apt-add-repositoryworks):apt install software-properties-common curl -y -
Install MaaS 3.3, running these commands one at a time:
apt-add-repository ppa:maas/3.3 apt update apt remove systemd-timesyncd -y apt install maas-region-controller -y apt install maas-rack-controller -y maas createadmin --username=<admin> --email=<email address>Replace
<admin>and<email address>. Set a non-trivial password and store it in your password manager. Optionally import an SSH public key.
C. Share services via Teleport
Reference video: Sharing services via Teleport.
On the Teleport server
-
Create a short-lived token to "invite" the MaaS application:
tctl tokens add \ --type=app,node \ --app-name=<dc>-maas \ --app-uri=http://localhost:5240Take note of the
tokenandca_pinvalues.
On the MaaS server
-
Install the Teleport agent (use the same Teleport version installed earlier):
sudo curl https://goteleport.com/static/install.sh | bash -s <teleport version> -
Create the Teleport application config:
sudo teleport configure --output=file \ --proxy=<domain name>:443 \ --token=/var/lib/teleport/token \ --roles=app,node \ --app-name=<dc>-maas \ --app-uri=http://localhost:5240 -
Save the token generated on the Teleport server:
sudo vi /var/lib/teleport/token -
Save the
ca_pin:sudo vi /var/lib/teleport/ca_pin -
Edit
/etc/teleport.yamlto update theca_pinresource:sudo vi /etc/teleport.yaml-
Set the
ca_pinresource path to/var/lib/teleport/ca_pin. -
Add a
labels:section underssh_service::labels: dc: "<dc>" login: "<admin user login>" -
Remove the
commands:section underssh_service::commands: - name: hostname command: [hostname] period: 1m0s -
Add
labels:underapp_service: -> apps: -> <dc>-maasservice:- name: <dc>-maas uri: http://localhost:5240 public_addr: "" insecure_skip_verify: false labels: dc: "<dc>" type: "maas"
Sample
/etc/teleport.yaml:version: v3 teleport: nodename: maas data_dir: /var/lib/teleport join_params: token_name: /var/lib/teleport/token method: token proxy_server: teleport.<domain>:443 log: output: stderr severity: INFO format: output: text ca_pin: /var/lib/teleport/ca_pin diag_addr: "" auth_service: enabled: "no" ssh_service: enabled: "yes" labels: dc: "<dc>" login: "maas" proxy_service: enabled: "no" https_keypairs: [] https_keypairs_reload_interval: 0s acme: {} app_service: enabled: "yes" debug_app: false apps: - name: bo1-maas uri: http://localhost:5240 public_addr: "" insecure_skip_verify: false labels: dc: "<dc>" type: "maas" -
-
Add Teleport to
/etc/hosts:sudo vi /etc/hostsAdd an entry:
10.10.100.22 <Domain name of your teleport server>Save and quit the file.
-
Start the Teleport agent:
sudo systemctl enable teleport sudo systemctl start teleport
D. Initial configuration of MaaS server
- Log in to the Teleport server and click Launch next to the new MaaS resource to perform the initial MaaS configuration.
- Sign in to the MaaS web GUI using the credentials you created in the previous section.
- Set the DNS forwarder list to
1.1.1.1 8.8.8.8and click Save and continue. - Select the Ubuntu release 22.04 LTS and architecture AMD64, click Update selection, then Continue.
- Click Finish setup.
- Import any additional SSH keys for the
dfnadminuser, then click Finish setup again.
E. Configure DHCP subnet on MaaS
-
Click Subnets in the top navigation bar.
-
Click
10.10.100.0/24. -
Click Reserve Range > Reserve dynamic range.
-
Configure the dynamic range:
- Start IP address:
10.10.100.53 - End IP address:
10.10.100.99
Click Reserve.
- Start IP address:
-
Click Subnets in the top navigation bar.
-
Click untagged.
-
Click Configure DHCP.
-
Ensure MAAS provides DHCP is ticked.
-
Select Provide DHCP from rack controller(s).
-
In the Rack controller drop-down, select
<dc>-maasand click Configure DHCP.
Continue
Proceed to Best Practices: Proxmox Security.
Related
- RMU build — Gen-1.5 — the parent runbook index.
- RMU Build: Teleport Setup — the previous section.
- RMU Build: Best Practices — the next section.