Skip to content
Snippets Groups Projects
Commit db24c19b authored by MJB's avatar MJB
Browse files

#88 updates to readme and fixes for nested lxd

parent 04fa335c
No related branches found
No related tags found
No related merge requests found
......@@ -65,5 +65,5 @@ clean:
only:
- schedules
script:
- sudo scripts/test/fixture.sh destroy -f src/test/clmctest/rspec.json
- sudo scripts/test/fixture.sh destroy -f src/test/clmctest/rspec.json -r $CI_PROJECT_DIR
when: always
......@@ -113,7 +113,41 @@ pytest -s --pyargs clmctest.monitoring
#### CI Testing
A vagrant VM is setup on givry in the directory `/home/mjb/flame-clmc`
A lxd container is setup on givry called `clmc-ci`. The container is priviledged and allows for nested containers. The container was created using the following commands
```
lxc launch ubuntu:18.04 clmc-ci -c security.privileged=true -c security.nesting=true
lxc network attach br_ci clmc-ci eth0
lxc config device set clmc-ci eth0 ipv4.address 10.0.3.15
```
the container is then started and LXD initialised
```
lxc start clmc-ci
lxc exec clmc-ci -- bash
lxc init
```
Follow the interactive prompts, use the defaults apart from the storage pool type, use `dir` type
Configure ip table persistence
```
echo iptables-persistent iptables-persistent/autosave_v4 boolean true | sudo debconf-set-selections
echo iptables-persistent iptables-persistent/autosave_v6 boolean true | sudo debconf-set-selections
apt-get -y install iptables-persistent
```
The install git runner file was just copied to the container from a tmp director
```
cp /tmp/install-git-runner.sh /var/lib/lxd/containers/clmc-ci/rootfs/tmp
chmod 755 /var/lib/lxd/containers/clmc-ci/rootfs/tmp
```
The VM is started using a libvirt vagrant file through the following command:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment