mirror of
https://codeberg.org/demostf/frontend.git
synced 2026-08-02 20:34:46 +02:00
opentelemetry
This commit is contained in:
parent
6010f814e9
commit
62acb3692a
5 changed files with 289 additions and 25 deletions
|
|
@ -1,3 +1,4 @@
|
|||
use crate::error::SetupError;
|
||||
use crate::Result;
|
||||
use config::{Environment, File};
|
||||
use serde::Deserialize;
|
||||
|
|
@ -15,7 +16,7 @@ pub struct Config {
|
|||
}
|
||||
|
||||
impl Config {
|
||||
pub fn load(path: &str) -> Result<Self> {
|
||||
pub fn load(path: &str) -> Result<Self, SetupError> {
|
||||
let s = config::Config::builder()
|
||||
.add_source(File::with_name(path))
|
||||
.add_source(Environment::default().separator("_"))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue