From efdc558cbab75bae79be161f9f4ab2c6e6317451 Mon Sep 17 00:00:00 2001 From: Aiden McClelland <3732071+dr-bonez@users.noreply.github.com> Date: Mon, 20 Nov 2023 11:54:05 -0700 Subject: [PATCH] set content disposition for cert (#2527) * set content disposition for cert * update content type for cert * remove unnecessary frontend download attr --- core/startos/src/db/model.rs | 2 +- core/startos/src/init.rs | 6 +++--- core/startos/src/net/keys.rs | 2 +- core/startos/src/net/static_server.rs | 12 +++++++++--- .../pages/login/ca-wizard/ca-wizard.component.html | 3 --- .../ui/src/app/pages/server-routes/lan/lan.page.html | 4 ++-- .../ui/src/app/pages/server-routes/lan/lan.page.ts | 4 ---- 7 files changed, 16 insertions(+), 17 deletions(-) diff --git a/core/startos/src/db/model.rs b/core/startos/src/db/model.rs index bce8886caf..344d5abb37 100644 --- a/core/startos/src/db/model.rs +++ b/core/startos/src/db/model.rs @@ -22,7 +22,7 @@ use crate::net::utils::{get_iface_ipv4_addr, get_iface_ipv6_addr}; use crate::prelude::*; use crate::s9pk::manifest::{Manifest, PackageId}; use crate::status::Status; -use crate::util::cpupower::{get_preferred_governor, Governor}; +use crate::util::cpupower::{Governor}; use crate::util::Version; use crate::version::{Current, VersionT}; use crate::{ARCH, PLATFORM}; diff --git a/core/startos/src/init.rs b/core/startos/src/init.rs index 5818147707..4b057be007 100644 --- a/core/startos/src/init.rs +++ b/core/startos/src/init.rs @@ -4,7 +4,7 @@ use std::path::Path; use std::time::{Duration, SystemTime}; use color_eyre::eyre::eyre; -use helpers::NonDetachingJoinHandle; + use models::ResultExt; use rand::random; use sqlx::{Pool, Postgres}; @@ -18,9 +18,9 @@ use crate::disk::mount::util::unmount; use crate::install::PKG_ARCHIVE_DIR; use crate::middleware::auth::LOCAL_AUTH_COOKIE_PATH; use crate::prelude::*; -use crate::sound::BEP; + use crate::util::cpupower::{ - current_governor, get_available_governors, get_preferred_governor, set_governor, + get_available_governors, get_preferred_governor, set_governor, }; use crate::util::docker::{create_bridge_network, CONTAINER_DATADIR, CONTAINER_TOOL}; use crate::util::Invoke; diff --git a/core/startos/src/net/keys.rs b/core/startos/src/net/keys.rs index a64e3a1874..504bd276d3 100644 --- a/core/startos/src/net/keys.rs +++ b/core/startos/src/net/keys.rs @@ -280,7 +280,7 @@ pub fn test_keygen() { key.openssl_key_nistp256(); } -fn display_requires_reboot(arg: RequiresReboot, matches: &ArgMatches) { +fn display_requires_reboot(arg: RequiresReboot, _matches: &ArgMatches) { if arg.0 { println!("Server must be restarted for changes to take effect"); } diff --git a/core/startos/src/net/static_server.rs b/core/startos/src/net/static_server.rs index c4dca85f2f..761566a2c4 100644 --- a/core/startos/src/net/static_server.rs +++ b/core/startos/src/net/static_server.rs @@ -23,6 +23,7 @@ use tokio_util::io::ReaderStream; use crate::context::{DiagnosticContext, InstallContext, RpcContext, SetupContext}; use crate::core::rpc_continuations::RequestGuid; use crate::db::subscribe; +use crate::hostname::Hostname; use crate::install::PKG_PUBLIC_DIR; use crate::middleware::auth::{auth as auth_middleware, HasValidSession}; use crate::middleware::cors::cors; @@ -339,7 +340,8 @@ async fn main_embassy_ui(req: Request
, ctx: RpcContext) -> Result