Skip to content

Commit 5b17bf6

Browse files
committed
libvirt: use custom network with dhcp-ignore-clid (fixes #2)
1 parent 5ff8f6f commit 5b17bf6

File tree

4 files changed

+23
-17
lines changed

4 files changed

+23
-17
lines changed

README.md

+5-15
Original file line numberDiff line numberDiff line change
@@ -50,20 +50,6 @@ $ git clone https://github.com/servo/ci-runners.git /config
5050
$ /config/server/update.sh /config/server/nixos
5151
```
5252

53-
To set up libvirt:
54-
55-
- Connect via virt-manager on another machine
56-
- File > Add Connection…
57-
- \> Hypervisor: QEMU/KVM
58-
- \> Connect to remote host over SSH
59-
- \> Username: root
60-
- \> Hostname: ci0.servo.org
61-
- \> Connect
62-
- Configure and start the “default” network for NAT
63-
- Edit > Connection Details > Virtual Networks > default
64-
- \> Autostart: On Boot
65-
- \> Start Network
66-
6753
To get a GITHUB_TOKEN for the monitor service:
6854

6955
- [Create](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens) a [fine-grained personal access token](https://github.com/settings/personal-access-tokens/new)
@@ -77,9 +63,13 @@ To get a GITHUB_TOKEN for the monitor service:
7763
To set up the monitor service, run the following:
7864

7965
```
80-
$ rustup default stable
8166
$ zfs create tank/base
8267
$ zfs create tank/ci
68+
$ virsh net-define cinet.xml
69+
$ virsh net-autostart cinet
70+
$ virsh net-start cinet
71+
72+
$ rustup default stable
8373
$ git clone https://github.com/servo/servo.git ~/servo
8474
$ cp /config/.env.example /config/.env
8575
$ vim /config/.env

cinet.xml

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<network xmlns:dnsmasq="http://libvirt.org/schemas/network/dnsmasq/1.0">
2+
<name>cinet</name>
3+
<uuid>f606b6fd-b1e9-452f-a491-85ec319f34de</uuid>
4+
<forward mode="nat"/>
5+
<bridge name="cinet" stp="on" delay="0"/>
6+
<mac address="52:54:00:c3:0f:3e"/>
7+
<ip address="192.168.100.1" netmask="255.255.255.0">
8+
<dhcp>
9+
<range start="192.168.100.100" end="192.168.100.199"/>
10+
</dhcp>
11+
</ip>
12+
<dnsmasq:options>
13+
<!-- servo/ci-runners#2; <https://gitlab.com/libvirt/libvirt/-/issues/249> -->
14+
<dnsmasq:option value="dhcp-ignore-clid"/>
15+
</dnsmasq:options>
16+
</network>

ubuntu2204.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@
132132
</controller>
133133
<interface type='network'>
134134
<mac address='52:54:00:b8:b3:dd'/>
135-
<source network='default'/>
135+
<source network='cinet'/>
136136
<model type='virtio'/>
137137
<address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
138138
</interface>

windows10.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@
159159
</controller>
160160
<interface type='network'>
161161
<mac address='52:54:00:af:68:a3'/>
162-
<source network='default'/>
162+
<source network='cinet'/>
163163
<model type='virtio'/>
164164
<address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
165165
</interface>

0 commit comments

Comments
 (0)