From cf37950828edf1d9614a3d1eeb705cd3a6f5d41f Mon Sep 17 00:00:00 2001 From: Alexis Sellier Date: Fri, 31 Mar 2023 17:18:35 +0200 Subject: [PATCH] node: Rename control socket The old name, `radicle.sock` didn't tell us much about the purpose of this socket. --- HACKING.md | 2 +- radicle-cli/examples/rad-auth.md | 2 +- radicle-cli/src/commands/self.rs | 4 ++-- radicle/src/node.rs | 2 +- radicle/src/profile.rs | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/HACKING.md b/HACKING.md index f237415c..01862477 100644 --- a/HACKING.md +++ b/HACKING.md @@ -155,7 +155,7 @@ remote refs in storage. ### Connecting to your local node The radicle node listens on a UNIX domain socket located at -`$RAD_HOME/node/radicle.sock`. Make sure this file is accessible and has the +`$RAD_HOME/node/control.sock`. Make sure this file is accessible and has the required permissions for your user to read and write to it. ### Radicle keys diff --git a/radicle-cli/examples/rad-auth.md b/radicle-cli/examples/rad-auth.md index 207f306e..dc671bee 100644 --- a/radicle-cli/examples/rad-auth.md +++ b/radicle-cli/examples/rad-auth.md @@ -23,5 +23,5 @@ Key (hash) SHA256:UIedaL6Cxm6OUErh9GQUzzglSk7VpQlVTI1TAFB/HWA Key (full) ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHahWSBEpuT1ESZbynOmBNkLBSnR32Ar4woZqSV2YNH1 Storage (git) [..]/storage Storage (keys) [..]/keys -Node (socket) [..]/node/radicle.sock +Node (socket) [..]/node/control.sock ``` diff --git a/radicle-cli/src/commands/self.rs b/radicle-cli/src/commands/self.rs index e15e9ab2..bb63eb7f 100644 --- a/radicle-cli/src/commands/self.rs +++ b/radicle-cli/src/commands/self.rs @@ -138,10 +138,10 @@ fn all(profile: &Profile) -> anyhow::Result<()> { term::format::tertiary(keys_path.display()).to_string(), ]); - let node_path = profile.home.node(); + let socket_path = profile.socket(); table.push([ term::format::style("Node (socket)").to_string(), - term::format::tertiary(node_path.join("radicle.sock").display()).to_string(), + term::format::tertiary(socket_path.display()).to_string(), ]); table.print(); diff --git a/radicle/src/node.rs b/radicle/src/node.rs index e87ab9ac..39c78e3d 100644 --- a/radicle/src/node.rs +++ b/radicle/src/node.rs @@ -22,7 +22,7 @@ use crate::storage::RefUpdate; pub use features::Features; /// Default name for control socket file. -pub const DEFAULT_SOCKET_NAME: &str = "radicle.sock"; +pub const DEFAULT_SOCKET_NAME: &str = "control.sock"; /// Default radicle protocol port. pub const DEFAULT_PORT: u16 = 8776; /// Filename of routing table database under the node directory. diff --git a/radicle/src/profile.rs b/radicle/src/profile.rs index 1aabdaf1..8811e7f0 100644 --- a/radicle/src/profile.rs +++ b/radicle/src/profile.rs @@ -8,7 +8,7 @@ //! radicle # Secret key (PKCS 8) //! radicle.pub # Public key (PKCS 8) //! node/ -//! radicle.sock # Node control socket +//! control.sock # Node control socket //! use std::path::{Path, PathBuf}; use std::{fs, io};