We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3ccbc1f commit b4f2974Copy full SHA for b4f2974
samba.sh
@@ -4,6 +4,7 @@ set -Eeuo pipefail
4
# Set variables for group and share directory
5
group="smb"
6
share="/storage"
7
+secret="/run/secrets/pass"
8
9
# Create shared directory
10
mkdir -p "$share" || { echo "Failed to create directory $share"; exit 1; }
@@ -71,8 +72,8 @@ else
71
72
fi
73
74
# Check if the secret file exists and if its size is greater than zero
-if [ -s "$PASS_SECRETFILE" ]; then
75
- PASS=$(cat "$PASS_SECRETFILE")
+if [ -s "$secret" ]; then
76
+ PASS=$(cat "$secret")
77
78
79
# Change Samba password
0 commit comments