forked from valeriansaliou/vigil
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
da69a80
commit 3aef1a5
Showing
7 changed files
with
158 additions
and
28 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// Vigil | ||
// | ||
// Microservices Status Page | ||
// Copyright: 2022, Valerian Saliou <[email protected]> | ||
// License: Mozilla Public License v2.0 (MPL v2.0) | ||
|
||
use std::sync::Arc; | ||
use std::sync::RwLock; | ||
|
||
lazy_static! { | ||
pub static ref STORE: Arc<RwLock<Store>> = Arc::new(RwLock::new(Store { | ||
announcements: Vec::new(), | ||
})); | ||
} | ||
|
||
pub struct Store { | ||
pub announcements: Vec<Announcement>, | ||
} | ||
|
||
#[derive(Serialize)] | ||
pub struct Announcement { | ||
title: String, | ||
text: String, | ||
date: Option<String>, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,6 +4,7 @@ | |
// Copyright: 2018, Valerian Saliou <[email protected]> | ||
// License: Mozilla Public License v2.0 (MPL v2.0) | ||
|
||
mod announcements; | ||
mod context; | ||
mod payload; | ||
mod routes; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters