mirror of
https://github.com/ryantm/agenix.git
synced 2024-11-22 09:40:47 +03:00
Revert to hdiutil for older macos compatibility, be explicit about the weird number after ram://
This commit is contained in:
parent
9779a98f1e
commit
6ec0b0f7c7
1 changed files with 2 additions and 1 deletions
|
@ -23,7 +23,8 @@ with lib; let
|
||||||
if isDarwin
|
if isDarwin
|
||||||
then ''
|
then ''
|
||||||
if ! diskutil info "${cfg.secretsMountPoint}" &> /dev/null; then
|
if ! diskutil info "${cfg.secretsMountPoint}" &> /dev/null; then
|
||||||
dev=$(diskutil image attach -mountPolicy=noMount ram://1MiB | sed 's/[[:space:]]*$//')
|
num_sectors=1048576
|
||||||
|
dev=$(hdiutil attach -nomount ram://"$num_sectors" | sed 's/[[:space:]]*$//')
|
||||||
newfs_hfs -v agenix "$dev"
|
newfs_hfs -v agenix "$dev"
|
||||||
mount -t hfs -o nobrowse,nodev,nosuid,-m=0751 "$dev" "${cfg.secretsMountPoint}"
|
mount -t hfs -o nobrowse,nodev,nosuid,-m=0751 "$dev" "${cfg.secretsMountPoint}"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue