Set secrete_key to fix cookie persistence

rust
Elnu 1 year ago
parent 53de257960
commit 1f33a60f7a

@ -1,3 +1,5 @@
CLIENT_ID=
CLIENT_SECRET=
DOMAIN=https://tegakituesday.com/
DOMAIN=https://tegakituesday.com/
# head -c64 /dev/urandom | base64
SECRET=

@ -309,8 +309,10 @@ impl User {
#[launch]
fn rocket() -> _ {
let config = rocket::Config::figment().merge(("port", 1313));
dotenv::dotenv().expect("Failed to load .env file");
let config = rocket::Config::figment()
.merge(("port", 1313))
.merge(("secret_key", env::var("SECRET").expect("Must have SECRET defined in .env for private cookie persistence")));
rocket::custom(config)
.mount(
"/",

Loading…
Cancel
Save