-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Docker & other things want access to the generated secret directories, yet you can't just bind-mount them elsewhere as deployer user might be different from app user, resulting in "Permission denied" errors. Grant other users permission to read secret files and access secret directories without giving access to the outer directories. * Set correct permissions for all files and dirs * Fixes after review
- Loading branch information
Showing
5 changed files
with
35 additions
and
8 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
use std::{fs::DirBuilder, io, os::unix::fs::DirBuilderExt, path::Path}; | ||
|
||
/// Recursively create a directory and all of its parent components if they | ||
/// are missing with given permissions. | ||
/// | ||
/// # Errors | ||
/// | ||
/// The same as from [`std::fs::create_dir_all`] | ||
pub fn create_dir_mode<P: AsRef<Path>>(path: P, mode: u32) -> io::Result<()> { | ||
DirBuilder::new() | ||
.recursive(true) | ||
.mode(mode) | ||
.create(path.as_ref()) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters