Change service
This commit is contained in:
@@ -5,7 +5,7 @@ After=keycloak
|
|||||||
[Service]
|
[Service]
|
||||||
Type=Simple
|
Type=Simple
|
||||||
WorkingDirectory=/usr/share/nginx/inventur/
|
WorkingDirectory=/usr/share/nginx/inventur/
|
||||||
ExecStart=/usr/bin/inventur
|
ExecStart=/usr/local/bin/inventur
|
||||||
User=nginx
|
User=nginx
|
||||||
Group=nginx
|
Group=nginx
|
||||||
Restart=always
|
Restart=always
|
||||||
|
|||||||
0
inventur/inventur_db/migrations/.keep
Normal file
0
inventur/inventur_db/migrations/.keep
Normal file
@@ -6,3 +6,4 @@ edition = "2021"
|
|||||||
[dependencies]
|
[dependencies]
|
||||||
diesel = { version = "2.2.0", features = ["mysql"] }
|
diesel = { version = "2.2.0", features = ["mysql"] }
|
||||||
dotenvy = "0.15"
|
dotenvy = "0.15"
|
||||||
|
|
||||||
|
|||||||
@@ -6,4 +6,4 @@ file = "src/schema.rs"
|
|||||||
custom_type_derives = ["diesel::query_builder::QueryId", "Clone"]
|
custom_type_derives = ["diesel::query_builder::QueryId", "Clone"]
|
||||||
|
|
||||||
[migrations_directory]
|
[migrations_directory]
|
||||||
dir = "/home/johannes/code/inventur/inventur_db/migrations"
|
dir = "/opt/inventur/inventur/inventur_db/migrations"
|
||||||
|
|||||||
@@ -68,7 +68,7 @@ pub async fn login_or_register(conn: Db, access_token: &str) -> Option<inventur_
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#[catch(401)]
|
#[catch(403)]
|
||||||
pub async fn redirect_to_login() -> Redirect {
|
pub async fn redirect_to_login() -> Redirect {
|
||||||
Redirect::to(uri!(oauth_login()))
|
Redirect::to(uri!(oauth_login()))
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user