mirror of
https://github.com/pocket-id/pocket-id.git
synced 2026-02-12 19:05:14 +00:00
fix: correctly set script permissions inside Docker container
This commit is contained in:
@@ -46,7 +46,7 @@ COPY --from=frontend-builder /app/frontend/package.json ./frontend/package.json
|
|||||||
COPY --from=backend-builder /app/backend/pocket-id-backend ./backend/pocket-id-backend
|
COPY --from=backend-builder /app/backend/pocket-id-backend ./backend/pocket-id-backend
|
||||||
|
|
||||||
COPY ./scripts ./scripts
|
COPY ./scripts ./scripts
|
||||||
RUN chmod +x ./scripts/**/*.sh
|
RUN find ./scripts -name "*.sh" -exec chmod +x {} \;
|
||||||
|
|
||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
ENV APP_ENV=production
|
ENV APP_ENV=production
|
||||||
|
|||||||
@@ -1,3 +1,5 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
DB_PATH="./backend/data/pocket-id.db"
|
DB_PATH="./backend/data/pocket-id.db"
|
||||||
DB_PROVIDER="${DB_PROVIDER:=sqlite}"
|
DB_PROVIDER="${DB_PROVIDER:=sqlite}"
|
||||||
|
|
||||||
@@ -32,8 +34,14 @@ check_and_install() {
|
|||||||
local cmd=$1
|
local cmd=$1
|
||||||
local pkg=$2
|
local pkg=$2
|
||||||
|
|
||||||
if ! command -v "$cmd" &>/dev/null; then
|
if
|
||||||
if command -v apk &>/dev/null; then
|
! command -v "$cmd" &
|
||||||
|
>/dev/null
|
||||||
|
then
|
||||||
|
if
|
||||||
|
command -v apk &
|
||||||
|
>/dev/null
|
||||||
|
then
|
||||||
echo "$cmd not found. Installing..."
|
echo "$cmd not found. Installing..."
|
||||||
apk add "$pkg" --no-cache
|
apk add "$pkg" --no-cache
|
||||||
else
|
else
|
||||||
@@ -105,4 +113,4 @@ else
|
|||||||
echo "Error creating access token."
|
echo "Error creating access token."
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
echo "================================================="
|
echo "================================================="
|
||||||
|
|||||||
Reference in New Issue
Block a user