This commit is contained in:
parent
6fa01228c0
commit
cf5f641012
1 changed files with 22 additions and 17 deletions
39
src/main.rs
39
src/main.rs
|
@ -56,23 +56,20 @@ async fn launch(config: String) {
|
|||
..Default::default()
|
||||
})
|
||||
.mount_assets()
|
||||
.mount(
|
||||
"/",
|
||||
routes![
|
||||
routes::index_page,
|
||||
routes::pkg_route,
|
||||
routes::push::upload_pkg,
|
||||
routes::user::login,
|
||||
routes::user::login_post,
|
||||
routes::user::account_page,
|
||||
routes::ui::pkg_ui,
|
||||
routes::ui::repo_ui,
|
||||
routes::user::new_api_key,
|
||||
routes::user::end_session,
|
||||
routes::user::change_password,
|
||||
routes::user::change_password_post
|
||||
],
|
||||
)
|
||||
.mount("/", routes![
|
||||
routes::index_page,
|
||||
routes::pkg_route,
|
||||
routes::push::upload_pkg,
|
||||
routes::user::login,
|
||||
routes::user::login_post,
|
||||
routes::user::account_page,
|
||||
routes::ui::pkg_ui,
|
||||
routes::ui::repo_ui,
|
||||
routes::user::new_api_key,
|
||||
routes::user::end_session,
|
||||
routes::user::change_password,
|
||||
routes::user::change_password_post
|
||||
])
|
||||
.manage(config)
|
||||
.manage(shell)
|
||||
.launch()
|
||||
|
@ -114,6 +111,14 @@ pub fn build(image: &str, ci: bool) {
|
|||
"chown -R build /build".to_string(),
|
||||
]);
|
||||
|
||||
if ci {
|
||||
let chown_cmd = format!(
|
||||
"chown -R build {}",
|
||||
std::env::current_dir().unwrap().display()
|
||||
);
|
||||
docker_script.extend([chown_cmd]);
|
||||
}
|
||||
|
||||
if ci {
|
||||
if std::fs::exists("./pacman.conf").unwrap() {
|
||||
println!("-> Using custom pacman.conf");
|
||||
|
|
Loading…
Add table
Reference in a new issue