Skip to content

Commit

Permalink
Move nexus::internal_api::params into nexus-types
Browse files Browse the repository at this point in the history
  • Loading branch information
jgallagher committed Jul 22, 2022
1 parent d59a27c commit 91a79a4
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 6 deletions.
3 changes: 2 additions & 1 deletion nexus/src/internal_api/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@
// file, You can obtain one at https://mozilla.org/MPL/2.0/.

pub mod http_entrypoints;
pub mod params;

pub use nexus_types::internal_api::params;
4 changes: 0 additions & 4 deletions nexus/types/src/external_api/shared.rs
Original file line number Diff line number Diff line change
Expand Up @@ -272,15 +272,11 @@ pub enum IpKind {

#[cfg(test)]
mod test {
use super::IdentityType;
use super::Policy;
use super::MAX_ROLE_ASSIGNMENTS_PER_RESOURCE;
use crate::external_api::shared;
use crate::external_api::shared::IpRange;
use crate::external_api::shared::Ipv4Range;
use crate::external_api::shared::Ipv6Range;
use anyhow::anyhow;
use omicron_common::api::external::Error;
use serde::Deserialize;
use std::net::Ipv4Addr;
use std::net::Ipv6Addr;
Expand Down
2 changes: 1 addition & 1 deletion nexus/types/src/identity.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ pub trait Resource {
fn identity(&self) -> IdentityMetadata {
IdentityMetadata {
id: self.id(),
name: self.name().clone().into(),
name: self.name().clone(),
description: self.description().to_string(),
time_created: self.time_created(),
time_modified: self.time_modified(),
Expand Down
5 changes: 5 additions & 0 deletions nexus/types/src/internal_api/mod.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at https://mozilla.org/MPL/2.0/.

pub mod params;
File renamed without changes.
1 change: 1 addition & 0 deletions nexus/types/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@

pub mod external_api;
pub mod identity;
pub mod internal_api;

0 comments on commit 91a79a4

Please sign in to comment.