Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #37919 from nextcloud/backport/stable25/sso-kerber…
…os-fix [stable25] Update kerberos sso test setup to use new user_saml config system
- Loading branch information
Showing
5 changed files
with
65 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#!/usr/bin/env bash | ||
|
||
DC_IP=$1 | ||
shift | ||
|
||
docker run --rm --name client -v /tmp/shared:/shared --dns $DC_IP --hostname client.domain.test icewind1991/samba-krb-test-client $@ |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#!/usr/bin/env bash | ||
|
||
docker rm -f apache 2>/dev/null > /dev/null | ||
|
||
docker run -d --name apache -v $2:/var/www/html -v /tmp/shared:/shared --dns $1 --hostname httpd.domain.test icewind1991/samba-krb-test-apache 1>&2 | ||
APACHE_IP=$(docker inspect apache --format '{{.NetworkSettings.IPAddress}}') | ||
|
||
# add the dns record for apache | ||
docker exec dc samba-tool dns add krb.domain.test domain.test httpd A $APACHE_IP -U administrator --password=passwOrd1 1>&2 | ||
|
||
echo $APACHE_IP |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
#!/usr/bin/env bash | ||
|
||
function getContainerHealth { | ||
docker inspect --format "{{.State.Health.Status}}" $1 | ||
} | ||
|
||
function waitContainer { | ||
while STATUS=$(getContainerHealth $1); [ $STATUS != "healthy" ]; do | ||
if [ $STATUS == "unhealthy" ]; then | ||
echo "Failed!" 1>&2 | ||
exit -1 | ||
fi | ||
printf . 1>&2 | ||
lf=$'\n' | ||
sleep 1 | ||
done | ||
printf "$lf" 1>&2 | ||
} | ||
|
||
docker rm -f dc 2>/dev/null > /dev/null | ||
|
||
mkdir -p /tmp/shared | ||
|
||
# start the dc | ||
docker run -dit --name dc -v /tmp/shared:/shared --hostname krb.domain.test --cap-add SYS_ADMIN icewind1991/samba-krb-test-dc 1>&2 | ||
|
||
waitContainer dc | ||
|
||
docker inspect dc --format '{{.NetworkSettings.IPAddress}}' |