tools: add deploy-qemu and gen-user-data
tools/gen-user-data generates a cloud-init user-data file from a configuration directory. It is mostly useful to embed files in the user-data. tools/deploy-qemu uses above tool to make a user-data file and spins up a virtual machine with it. This is useful to locally run, test, and debug osbuild-composer. A simple user-data directory for running tests locally is included in tests/deploy-user-data. It expects a repository with osbuild-composer rpms to be served on the host's port 8000.
This commit is contained in:
parent
122ab25476
commit
857570980d
6 changed files with 191 additions and 0 deletions
5
tools/deploy/test/files/run/provision-scripts/deploy.sh
Executable file
5
tools/deploy/test/files/run/provision-scripts/deploy.sh
Executable file
|
|
@ -0,0 +1,5 @@
|
|||
#!/bin/bash
|
||||
|
||||
set -euxo pipefail
|
||||
|
||||
dnf -y install osbuild-composer-tests
|
||||
1
tools/deploy/test/files/run/provision-scripts/provision.sh
Symbolic link
1
tools/deploy/test/files/run/provision-scripts/provision.sh
Symbolic link
|
|
@ -0,0 +1 @@
|
|||
../../../../../../schutzbot/provision.sh
|
||||
16
tools/deploy/test/user-data.yml
Normal file
16
tools/deploy/test/user-data.yml
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
#cloud-config
|
||||
yum_repos:
|
||||
osbuild:
|
||||
name: osbuild
|
||||
baseurl: "http://10.0.2.2:8000"
|
||||
enabled: true
|
||||
gpgcheck: false
|
||||
user: admin
|
||||
password: foobar
|
||||
ssh_pwauth: True
|
||||
chpasswd:
|
||||
expire: False
|
||||
sudo: 'ALL=(ALL) NOPASSWD:ALL'
|
||||
runcmd:
|
||||
- /run/provision-scripts/deploy.sh
|
||||
- /run/provision-scripts/provision.sh
|
||||
Loading…
Add table
Add a link
Reference in a new issue