mirror of
https://github.com/ceph/ceph
synced 2025-01-01 08:32:24 +00:00
567024d363
This adds a QA suite for the service token auth in RGW. The suite runs a workunit that is a bash script that spawns a fake Keystone server which is then used as an auth backend for RGW to test the feature. A python script is then executed that runs a battery of tests against RadosGW which talks to the fake Keystone server running in the background. Signed-off-by: Tobias Urdin <tobias.urdin@binero.com>
35 lines
978 B
Bash
Executable File
35 lines
978 B
Bash
Executable File
#!/usr/bin/env bash
|
|
#
|
|
# Copyright (C) 2022 Binero
|
|
#
|
|
# Author: Tobias Urdin <tobias.urdin@binero.com>
|
|
#
|
|
# This program is free software; you can redistribute it and/or modify
|
|
# it under the terms of the GNU Library Public License as published by
|
|
# the Free Software Foundation; either version 2, or (at your option)
|
|
# any later version.
|
|
#
|
|
# This program is distributed in the hope that it will be useful,
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
# GNU Library Public License for more details.
|
|
|
|
source $CEPH_ROOT/qa/standalone/ceph-helpers.sh
|
|
|
|
trap cleanup EXIT
|
|
|
|
function cleanup() {
|
|
kill $KEYSTONE_FAKE_SERVER_PID
|
|
wait
|
|
}
|
|
|
|
function run() {
|
|
$CEPH_ROOT/qa/workunits/rgw//keystone-fake-server.py &
|
|
KEYSTONE_FAKE_SERVER_PID=$!
|
|
# Give fake Keystone server some seconds to startup
|
|
sleep 5
|
|
$CEPH_ROOT/qa/workunits/rgw/test-keystone-service-token.py
|
|
}
|
|
|
|
main keystone-service-token "$@"
|