Spaces:
Sleeping
Sleeping
circulartext
commited on
Commit
•
1feaa37
1
Parent(s):
8f503f3
Update entrypoint.sh
Browse files- entrypoint.sh +0 -11
entrypoint.sh
CHANGED
@@ -1,17 +1,6 @@
|
|
1 |
#!/bin/bash
|
2 |
set -e
|
3 |
|
4 |
-
# Use the USER_ID environment variable or default to 1000
|
5 |
-
USER_ID=${USER_ID:-1000}
|
6 |
-
|
7 |
-
# Check if the user already exists
|
8 |
-
if id "$USER_ID" >/dev/null 2>&1; then
|
9 |
-
echo "User with ID $USER_ID already exists."
|
10 |
-
else
|
11 |
-
echo "Creating user with ID $USER_ID."
|
12 |
-
# Create a new user with the specified ID
|
13 |
-
useradd -m -u "$USER_ID" user
|
14 |
-
fi
|
15 |
|
16 |
# Run the CMD or any other command you want to execute
|
17 |
exec "$@"
|
|
|
1 |
#!/bin/bash
|
2 |
set -e
|
3 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
4 |
|
5 |
# Run the CMD or any other command you want to execute
|
6 |
exec "$@"
|