From bf025b4977543a371df9dbdddfe9cc2f02f2a8d0 Mon Sep 17 00:00:00 2001 From: Joel Klinghed Date: Sun, 9 Feb 2025 23:56:38 +0100 Subject: First integration test Sets up a whole slew of docker instances, all started from clean slate for test. --- docker/integration_test/web/setup.sh | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100755 docker/integration_test/web/setup.sh (limited to 'docker/integration_test/web/setup.sh') diff --git a/docker/integration_test/web/setup.sh b/docker/integration_test/web/setup.sh new file mode 100755 index 0000000..bd6c805 --- /dev/null +++ b/docker/integration_test/web/setup.sh @@ -0,0 +1,25 @@ +#!/bin/bash + +echo "[default]" > Rocket.toml +echo "address = \"0.0.0.0\"" >> Rocket.toml +echo "secret_key = \"itlYmFR2vYKrOmFhupMIn/hyB6lYCCTXz4yaQX89XVg=\"" >> Rocket.toml +echo "session_max_age_days = 7" >> Rocket.toml +echo "ldap_url = \"$LDAP_URL\"" >> Rocket.toml +echo "ldap_users = \"ou=users,dc=example,dc=org\"" >> Rocket.toml +echo "ldap_filter = \"(objectClass=posixAccount)\"" >> Rocket.toml +echo "git_server_root = \"/git/repos\"" >> Rocket.toml +echo "authorized_keys = \"/git/auth/authorized_keys\"" >> Rocket.toml +echo "git_hook = \"/git/repos/eyeballs-githook\"" >> Rocket.toml +echo "[default.databases.eyeballs]" >> Rocket.toml +echo "url = \"$DB_URL\"" >> Rocket.toml + +export RUST_BACKTRACE=1 +export HOME=/app + +echo "Host remote_git" > /app/.ssh/config +echo " StrictHostKeyChecking no" >> /app/.ssh/config + +# Hardlinks cannot cross devices, so copy to the /git/repos mount. +cp /app/eyeballs-githook /git/repos/eyeballs-githook + +exec ./eyeballs -- cgit v1.2.3-70-g09d2