Skip to content

Commit

Permalink
Fix initialization of CID dir
Browse files Browse the repository at this point in the history
chmod to the wrong path
  • Loading branch information
schaefi committed Nov 27, 2024
1 parent 5901484 commit ad13acc
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
1 change: 0 additions & 1 deletion podman-pilot/src/defaults.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
// SOFTWARE.
//
pub const CONTAINER_DIR: &str = "/var/lib/containers";
pub const GC_THRESHOLD: i32 = 20;
pub const HOST_DEPENDENCIES: &str = "removed";
pub const PODMAN_PATH: &str = "/usr/bin/podman";
Expand Down
3 changes: 1 addition & 2 deletions podman-pilot/src/podman.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
use crate::defaults;
use crate::config::{RuntimeSection, config};

use flakes::user::{User, chmod, mkdir};
use flakes::user::{User, mkdir};
use flakes::lookup::Lookup;
use flakes::io::IO;
use flakes::error::FlakeError;
Expand Down Expand Up @@ -564,7 +564,6 @@ pub fn init_cid_dir() -> Result<(), FlakeError> {
Create meta data directory structure
!*/
if ! Path::new(&get_podman_ids_dir()).is_dir() {
chmod(defaults::CONTAINER_DIR, "755", User::ROOT)?;
mkdir(&get_podman_ids_dir(), "777", User::ROOT)?;
}
Ok(())
Expand Down

0 comments on commit ad13acc

Please sign in to comment.