diff --git a/.buildkite/postgres-config.yaml b/ci/postgres-config.yaml
index 67e17fa9d1..511fef495d 100644
--- a/.buildkite/postgres-config.yaml
+++ b/ci/postgres-config.yaml
@@ -3,7 +3,7 @@
# CI's Docker setup at the point where this file is considered.
server_name: "localhost:8800"
-signing_key_path: ".buildkite/test.signing.key"
+signing_key_path: "ci/test.signing.key"
report_stats: false
@@ -11,7 +11,7 @@ database:
name: "psycopg2"
args:
user: postgres
- host: postgres
+ host: localhost
password: postgres
database: synapse
diff --git a/.buildkite/scripts/postgres_exec.py b/ci/scripts/postgres_exec.py
index 086b391724..0f39a336d5 100755
--- a/.buildkite/scripts/postgres_exec.py
+++ b/ci/scripts/postgres_exec.py
@@ -23,7 +23,7 @@ import psycopg2
# We use "postgres" as a database because it's bound to exist and the "synapse" one
# doesn't exist yet.
db_conn = psycopg2.connect(
- user="postgres", host="postgres", password="postgres", dbname="postgres"
+ user="postgres", host="localhost", password="postgres", dbname="postgres"
)
db_conn.autocommit = True
cur = db_conn.cursor()
diff --git a/.buildkite/scripts/test_synapse_port_db.sh b/ci/scripts/test_synapse_port_db.sh
index 82d7d56d4e..9ee0ad42fc 100755
--- a/.buildkite/scripts/test_synapse_port_db.sh
+++ b/ci/scripts/test_synapse_port_db.sh
@@ -20,22 +20,22 @@ pip install -e .
echo "--- Generate the signing key"
# Generate the server's signing key.
-python -m synapse.app.homeserver --generate-keys -c .buildkite/sqlite-config.yaml
+python -m synapse.app.homeserver --generate-keys -c ci/sqlite-config.yaml
echo "--- Prepare test database"
# Make sure the SQLite3 database is using the latest schema and has no pending background update.
-scripts-dev/update_database --database-config .buildkite/sqlite-config.yaml
+scripts-dev/update_database --database-config ci/sqlite-config.yaml
# Create the PostgreSQL database.
-./.buildkite/scripts/postgres_exec.py "CREATE DATABASE synapse"
+./ci/scripts/postgres_exec.py "CREATE DATABASE synapse"
echo "+++ Run synapse_port_db against test database"
-coverage run scripts/synapse_port_db --sqlite-database .buildkite/test_db.db --postgres-config .buildkite/postgres-config.yaml
+coverage run scripts/synapse_port_db --sqlite-database ci/test_db.db --postgres-config ci/postgres-config.yaml
# We should be able to run twice against the same database.
echo "+++ Run synapse_port_db a second time"
-coverage run scripts/synapse_port_db --sqlite-database .buildkite/test_db.db --postgres-config .buildkite/postgres-config.yaml
+coverage run scripts/synapse_port_db --sqlite-database ci/test_db.db --postgres-config ci/postgres-config.yaml
#####
@@ -44,14 +44,14 @@ coverage run scripts/synapse_port_db --sqlite-database .buildkite/test_db.db --p
echo "--- Prepare empty SQLite database"
# we do this by deleting the sqlite db, and then doing the same again.
-rm .buildkite/test_db.db
+rm ci/test_db.db
-scripts-dev/update_database --database-config .buildkite/sqlite-config.yaml
+scripts-dev/update_database --database-config ci/sqlite-config.yaml
# re-create the PostgreSQL database.
-./.buildkite/scripts/postgres_exec.py \
+./ci/scripts/postgres_exec.py \
"DROP DATABASE synapse" \
"CREATE DATABASE synapse"
echo "+++ Run synapse_port_db against empty database"
-coverage run scripts/synapse_port_db --sqlite-database .buildkite/test_db.db --postgres-config .buildkite/postgres-config.yaml
+coverage run scripts/synapse_port_db --sqlite-database ci/test_db.db --postgres-config ci/postgres-config.yaml
diff --git a/.buildkite/sqlite-config.yaml b/ci/sqlite-config.yaml
index d16459cfd9..fd5a1c1451 100644
--- a/.buildkite/sqlite-config.yaml
+++ b/ci/sqlite-config.yaml
@@ -3,14 +3,14 @@
# schema and run background updates on it.
server_name: "localhost:8800"
-signing_key_path: ".buildkite/test.signing.key"
+signing_key_path: "ci/test.signing.key"
report_stats: false
database:
name: "sqlite3"
args:
- database: ".buildkite/test_db.db"
+ database: "ci/test_db.db"
# Suppress the key server warning.
trusted_key_servers: []
|