mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-26 10:21:52 +00:00
check environment (#1990)
* check environment * fix tests * don't rebuild sources * I'm going insane * WTF * Update check-environment.sh * Update product.yaml * Update write-image.sh
This commit is contained in:
@@ -32,7 +32,7 @@ async fn setup_or_init(cfg_path: Option<PathBuf>) -> Result<(), Error> {
|
||||
let ctx = InstallContext::init(cfg_path).await?;
|
||||
|
||||
let embassy_ip_fqdn: ResourceFqdn = ResourceFqdn::IpAddr;
|
||||
let embassy_fqdn: ResourceFqdn = "pureos.local".parse()?;
|
||||
let embassy_fqdn: ResourceFqdn = "embassy.local".parse()?;
|
||||
|
||||
let localhost_fqdn = ResourceFqdn::LocalHost;
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#![recursion_limit = "256"]
|
||||
|
||||
pub const DEFAULT_MARKETPLACE: &str = "https://registry.start9.com";
|
||||
pub const COMMUNITY_MARKETPLACE: &str = "https://community-registry.start9.com";
|
||||
// pub const COMMUNITY_MARKETPLACE: &str = "https://community-registry.start9.com";
|
||||
pub const BUFFER_SIZE: usize = 1024;
|
||||
pub const HOST_IP: [u8; 4] = [172, 18, 0, 1];
|
||||
pub const TARGET: &str = current_platform::CURRENT_PLATFORM;
|
||||
|
||||
@@ -4,7 +4,7 @@ use serde_json::{json, Value};
|
||||
|
||||
use super::v0_3_0::V0_3_0_COMPAT;
|
||||
use super::*;
|
||||
use crate::{COMMUNITY_MARKETPLACE, DEFAULT_MARKETPLACE};
|
||||
use crate::DEFAULT_MARKETPLACE;
|
||||
|
||||
const V0_3_3: emver::Version = emver::Version::new(0, 3, 3, 0);
|
||||
|
||||
@@ -104,14 +104,12 @@ impl VersionT for Version {
|
||||
#[derive(Debug, Clone, Copy)]
|
||||
pub enum MarketPlaceUrls {
|
||||
Default,
|
||||
Community,
|
||||
}
|
||||
|
||||
impl MarketPlaceUrls {
|
||||
pub fn url(&self) -> String {
|
||||
let url_string = match self {
|
||||
MarketPlaceUrls::Default => DEFAULT_MARKETPLACE,
|
||||
MarketPlaceUrls::Community => COMMUNITY_MARKETPLACE,
|
||||
};
|
||||
format!("{url_string}/")
|
||||
}
|
||||
@@ -121,7 +119,7 @@ impl MarketPlaceUrls {
|
||||
fn test_that_ui_includes_url() {
|
||||
let ui: Value =
|
||||
serde_json::from_str(include_str!("../../../frontend/patchdb-ui-seed.json")).unwrap();
|
||||
for market_place in [MarketPlaceUrls::Default, MarketPlaceUrls::Community] {
|
||||
for market_place in [MarketPlaceUrls::Default] {
|
||||
let url = market_place.url();
|
||||
assert!(
|
||||
!ui["marketplace"]["known-hosts"][&url].is_null(),
|
||||
|
||||
Reference in New Issue
Block a user