provision.sh: don't start local worker and Weldr with TLS auth
Do not start local worker (mask the unit) and Weldr API socket when provisioning the SUT with TLS client cert authentication method. This method is used only in the Service scenario, therefore starting these units / sockets was not reflecting the intended deployment. Modify `api.sh` to not rely on local worker. Modify `base_tests.sh` to provision SUT with TLS for `osbuild-auth-tests`, while provisioning SUT with no authentication method for the rest of test cases.
This commit is contained in:
parent
a4b0efb278
commit
45850639a0
6 changed files with 20 additions and 23 deletions
|
|
@ -171,8 +171,8 @@ fi
|
|||
|
||||
# start appropriate units
|
||||
case "${AUTH_METHOD}" in
|
||||
"${AUTH_METHOD_JWT}")
|
||||
# JWT is used only in the "Service" scenario. This means that:
|
||||
"${AUTH_METHOD_JWT}" | "${AUTH_METHOD_TLS}")
|
||||
# JWT / TLS are used only in the "Service" scenario. This means that:
|
||||
# - only remote workers will be used (no local worker)
|
||||
# - only Cloud API socket will be started (no Weldr API)
|
||||
sudo systemctl stop 'osbuild*'
|
||||
|
|
@ -194,17 +194,4 @@ case "${AUTH_METHOD}" in
|
|||
# enable Weldr API
|
||||
sudo systemctl start osbuild-composer.socket
|
||||
;;
|
||||
|
||||
*)
|
||||
# the default setup used previously for all tests
|
||||
sudo systemctl start osbuild-remote-worker.socket
|
||||
sudo systemctl start osbuild-composer.socket
|
||||
sudo systemctl start osbuild-composer-api.socket
|
||||
|
||||
# The keys were regenerated but osbuild-composer might be already running.
|
||||
# Let's try to restart it. In ideal world, this shouldn't be needed as every
|
||||
# test case is supposed to run on a pristine machine. However, this is
|
||||
# currently not true on Schutzbot
|
||||
sudo systemctl try-restart osbuild-composer
|
||||
;;
|
||||
esac
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue