mirror of
https://github.com/aleleba/aleleba-vscode-dockerfile-configuration.git
synced 2026-07-16 12:17:07 -06:00
fix: ensure user's home directory exists before writing .bashrc and update version to 3.2.25
This commit is contained in:
@@ -48,6 +48,13 @@ sed 's/^USER_ENV_//' |
|
|||||||
# Append the result to /usr/bin/.bashrc
|
# Append the result to /usr/bin/.bashrc
|
||||||
while IFS= read -r line
|
while IFS= read -r line
|
||||||
do
|
do
|
||||||
|
# Ensure the user's home directory exists before writing .bashrc
|
||||||
|
if [ ! -d "/home/${HOME_USER}" ]; then
|
||||||
|
sudo mkdir -p "/home/${HOME_USER}"
|
||||||
|
sudo chown root:root "/home/${HOME_USER}"
|
||||||
|
sudo chmod 755 "/home/${HOME_USER}"
|
||||||
|
fi
|
||||||
|
|
||||||
# Check if the current user is root
|
# Check if the current user is root
|
||||||
if [ "$(id -u)" = "0" ]; then
|
if [ "$(id -u)" = "0" ]; then
|
||||||
echo "" >> /usr/bin/.bashrc
|
echo "" >> /usr/bin/.bashrc
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
3.2.24
|
3.2.25
|
||||||
|
|||||||
Reference in New Issue
Block a user