Skip to content

Commit

Permalink
Downgrade Rust to v1.66.1
Browse files Browse the repository at this point in the history
Signed-off-by: Sascha Grunert <[email protected]>
  • Loading branch information
saschagrunert committed Apr 23, 2024
1 parent cb6b7e6 commit d9724ce
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 72 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:
env:
CARGO_TERM_COLOR: always
GO_VERSION: '1.21'
ACTION_MSRV_TOOLCHAIN: 1.75.0
ACTION_MSRV_TOOLCHAIN: 1.66.1
NIX_VERSION: '2.21.0'
jobs:
build:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
env:
CARGO_TERM_COLOR: always
GO_VERSION: '1.21'
ACTION_MSRV_TOOLCHAIN: 1.75.0
ACTION_MSRV_TOOLCHAIN: 1.66.1

jobs:
build:
Expand Down
80 changes: 18 additions & 62 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions conmon-rs/server/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ libc = "0.2.153"
libsystemd = "0.7.0"
memchr = "2.7.2"
multimap = "0.10.0"
nix = { version = "0.28.0", features = ["fs", "hostname", "mount", "sched", "signal", "socket", "term", "user"] }
nix = { version = "=0.27.1", features = ["fs", "hostname", "mount", "sched", "signal", "socket", "term", "user"] }
notify = "6.1.1"
once_cell = "1.19.0"
opentelemetry = "0.22.0"
Expand Down Expand Up @@ -53,4 +53,4 @@ dashmap = "5.5.3"

[dev-dependencies]
mockall = "0.12.1"
time = { version = "0.3.36", features = ["parsing"] }
time = { version = "=0.3.23", features = ["parsing"] }
6 changes: 3 additions & 3 deletions conmon-rs/server/src/attach.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ use crate::{
use anyhow::{bail, Context, Result};
use nix::{
errno::Errno,
sys::socket::{bind, listen, socket, AddressFamily, Backlog, SockFlag, SockType, UnixAddr},
sys::socket::{bind, listen, socket, AddressFamily, SockFlag, SockType, UnixAddr},
};
use std::{
os::{
Expand Down Expand Up @@ -158,7 +158,7 @@ impl Attach {
let mut permissions = metadata.permissions();
permissions.set_mode(0o700);

listen(&fd, Backlog::new(10).context("create backlog")?).context("listen on socket fd")?;
listen(&fd, 10).context("listen on socket fd")?;

task::spawn(
async move {
Expand Down Expand Up @@ -246,7 +246,7 @@ impl Attach {
debug!("Read {} stdin bytes from client", buf.len());
tx.send(buf).context("send data message")?;
}
Err(e) => match Errno::from_raw(e.raw_os_error().context("get OS error")?) {
Err(e) => match Errno::from_i32(e.raw_os_error().context("get OS error")?) {
Errno::EIO => {
debug!("Stopping read loop because of IO error");
return Ok(());
Expand Down
2 changes: 1 addition & 1 deletion conmon-rs/server/src/container_io.rs
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,7 @@ impl ContainerIO {
}
}

Err(e) => match Errno::from_raw(e.raw_os_error().context("get OS error")?) {
Err(e) => match Errno::from_i32(e.raw_os_error().context("get OS error")?) {
Errno::EIO => {
debug!("Stopping read loop");
attach
Expand Down
4 changes: 2 additions & 2 deletions conmon-rs/server/src/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ use conmon_common::conmon_capnp::conmon::{self, CgroupManager};
use futures::{AsyncReadExt, FutureExt};
use getset::Getters;
use nix::{
errno::Errno,
errno,
libc::_exit,
sys::signal::Signal,
unistd::{fork, ForkResult},
Expand Down Expand Up @@ -123,7 +123,7 @@ impl Server {

// now that we've forked, set self to childreaper
prctl::set_child_subreaper(true)
.map_err(Errno::from_raw)
.map_err(errno::from_i32)
.context("set child subreaper")?;

let enable_tracing = self.config().enable_tracing();
Expand Down

0 comments on commit d9724ce

Please sign in to comment.