refactor: rename openfire.sql to clarify execution order

Renamed openfire.sql to 000-init-openfire.sql to make the initialisation order explicit in the filename. This helps when adding additional SQL scripts that need to run after the schema is created, as PostgreSQL executes files in /docker-entrypoint-initdb.d alphabetically.

The new openfire-integration-test repo uses this openfire-docker-compose repository as a base (using git submodules) for its tests but needs to reconfigure Openfire via the database before startup. To do this it overlays additional SQL files into this openfire-docker-compose repository's sql folders so they are run on startup. It has had to prefix its new SQL file with zz- to make sure it runs after the initialisation SQL file in our repository. This change should make future similar uses less complex/error-prone.
pull/78/head
Matthew Vivian 2025-01-06 15:47:48 +00:00 committed by Matthew Vivian
parent 3980e82267
commit 9d99ddbc8c
8 changed files with 2483 additions and 2483 deletions

View File

@ -316,7 +316,7 @@ mkdir -p ./xmpp/3
Export the database:
`docker exec -t openfire-testing_db3_1 pg_dump -U openfire openfire > ./sql/3/openfire.sql`
`docker exec -t openfire-testing_db3_1 pg_dump -U openfire openfire > ./sql/3/000-init-openfire.sql`
Export the Openfire configuration: