From f93ff38767e23602108f86992c453f7973dd8bd0 Mon Sep 17 00:00:00 2001 From: Harald Eilertsen Date: Mon, 4 Mar 2019 15:06:54 +0100 Subject: Set up database and connection pool with rocket_contrib::databases. Set the env var DATABASE_URL before running the server. A .env file in the root of the project is also supported. --- Cargo.toml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'Cargo.toml') diff --git a/Cargo.toml b/Cargo.toml index 08a340a..b9e3644 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -5,5 +5,10 @@ authors = ["haraldei"] edition = "2018" [dependencies] +dotenv = "0.13.0" rocket = "0.4.0" -rocket_contrib = { version = "0.4.0", default-features = false, features = ["serve"] } + +[dependencies.rocket_contrib] +version = "0.4.0" +default-features = false +features = ["serve", "diesel_postgres_pool"] -- cgit v1.2.3