WIP Install postgres and mysql dependencies. Add postgres to test, TODO Test all combinations postgres, sqlite and mysql/mariadb

This commit is contained in:
Sara Aimée Smiseth 2021-05-01 18:25:44 +02:00
parent d3f5a603e5
commit 3302ef9f0d
6 changed files with 30 additions and 26 deletions

View file

@ -1,21 +1,13 @@
default_storage = "sql"
-- TODO change if
--if DB_DRIVER then
sql = {
driver = os.getenv("DB_DRIVER"); -- May also be "PostgreSQL" or "MySQL" or "SQLite3" (case sensitive!)
database = os.getenv("DB_DATABASE"); -- The database name to use. For SQLite3 this the database filename (relative to the data storage directory).
host = os.getenv("DB_HOST"); -- The address of the database server (delete this line for Postgres)
port = os.getenv("DB_PORT"); -- 3306 - For databases connecting over TCP
username = os.getenv("DB_USERNAME"); -- The username to authenticate to the database
password = os.getenv("DB_PASSWORD"); -- The password to authenticate to the database
}
--else
--sql = {
--driver = "SQLite3";
--database = "prosody.sqlite";
--}
--end
sql = {
driver = os.getenv("DB_DRIVER");
database = os.getenv("DB_DATABASE");
host = os.getenv("DB_HOST");
port = os.getenv("DB_PORT");
username = os.getenv("DB_USERNAME");
password = os.getenv("DB_PASSWORD");
}
-- make 0.10-distributed mod_mam use sql store
archive_store = "archive2" -- Use the same data store as prosody-modules mod_mam