diff options
Diffstat (limited to 'ops')
-rw-r--r-- | ops/journaldriver/Cargo.toml | 1 | ||||
-rw-r--r-- | ops/journaldriver/src/main.rs | 25 |
2 files changed, 6 insertions, 20 deletions
diff --git a/ops/journaldriver/Cargo.toml b/ops/journaldriver/Cargo.toml index 2c560d14061b..8cd211772684 100644 --- a/ops/journaldriver/Cargo.toml +++ b/ops/journaldriver/Cargo.toml @@ -3,6 +3,7 @@ name = "journaldriver" version = "1.1.0" authors = ["Vincent Ambo <mail@tazj.in>"] license = "GPL-3.0-or-later" +edition = "2021" [dependencies] anyhow = "1.0" diff --git a/ops/journaldriver/src/main.rs b/ops/journaldriver/src/main.rs index 1315d49eff49..fb195aab892f 100644 --- a/ops/journaldriver/src/main.rs +++ b/ops/journaldriver/src/main.rs @@ -31,28 +31,13 @@ //! `GOOGLE_APPLICATION_CREDENTIALS`, `GOOGLE_CLOUD_PROJECT` and //! `LOG_NAME` environment variables. -#[macro_use] -extern crate anyhow; -#[macro_use] -extern crate log; -#[macro_use] -extern crate serde_derive; -#[macro_use] -extern crate serde_json; -#[macro_use] -extern crate lazy_static; - -extern crate chrono; -extern crate env_logger; -extern crate medallion; -extern crate serde; -extern crate systemd; -extern crate ureq; - -use anyhow::{Context, Result}; +use anyhow::{bail, format_err, Context, Result}; use chrono::offset::LocalResult; use chrono::prelude::{DateTime, TimeZone, Utc}; -use serde_json::{from_str, Value}; +use lazy_static::lazy_static; +use log::{debug, error, info, trace}; +use serde::{Deserialize, Serialize}; +use serde_json::{from_str, json, Value}; use std::fs::{self, rename, File}; use std::io::{self, ErrorKind, Read, Write}; use std::path::PathBuf; |