mirror of
https://github.com/jokob-sk/NetAlertX.git
synced 2025-12-06 17:15:38 -08:00
Coderabbit suggestions
This commit is contained in:
@@ -24,7 +24,7 @@
|
||||
// "--network=host",
|
||||
],
|
||||
// ATTENTION: If running with --network=host, COMMENT `forwardPorts` OR ELSE THERE WILL BE NO WEBUI!
|
||||
"forwardPorts": [20211, 20212, 5678],
|
||||
"forwardPorts": [20211, 20212, 5678],
|
||||
"portsAttributes": { // the ports we care about
|
||||
"20211": {
|
||||
"label": "Frontend:Nginx+PHP"
|
||||
|
||||
@@ -17,7 +17,7 @@ ENV PYDEVD_DISABLE_FILE_VALIDATION=1
|
||||
COPY .devcontainer/resources/devcontainer-overlay/ /
|
||||
|
||||
# Install common tools, create user, and set up sudo
|
||||
RUN apk add --no-cache git nano vim jq php83-pecl-xdebug py3-pip nodejs sudo gpgconf pytest pytest-cov fish shfmt sudo
|
||||
RUN apk add --no-cache git nano vim jq php83-pecl-xdebug py3-pip nodejs sudo gpgconf pytest pytest-cov fish shfmt github-cli
|
||||
|
||||
RUN install -d -o netalertx -g netalertx -m 755 /services/php/modules && \
|
||||
cp -a /usr/lib/php83/modules/. /services/php/modules/ && \
|
||||
|
||||
@@ -6,10 +6,6 @@
|
||||
# Run this script after modifying the resource Dockerfile to refresh
|
||||
# the final .devcontainer/Dockerfile used by the devcontainer.
|
||||
|
||||
# Make a copy of the original Dockerfile to the .devcontainer folder
|
||||
# but remove the COPY . ${INSTALL_DIR}/ command from it. This avoids
|
||||
# overwriting /app (which uses symlinks to the workspace) and preserves
|
||||
# debugging capabilities inside the devcontainer.
|
||||
echo "Generating .devcontainer/Dockerfile"
|
||||
SCRIPT_DIR="$(CDPATH= cd -- "$(dirname -- "$0")" && pwd)"
|
||||
DEVCONTAINER_DIR="${SCRIPT_DIR%/scripts}"
|
||||
@@ -19,7 +15,7 @@ OUT_FILE="${DEVCONTAINER_DIR}/Dockerfile"
|
||||
|
||||
echo "Adding base Dockerfile from $ROOT_DIR..."
|
||||
|
||||
echo "# DO NOT MODIFY THIS FILE DIRECTLY. IT IS AUTO-GENERATED BY .devcontainer/scripts/generate-dockerfile.sh" > "$OUT_FILE"
|
||||
echo "# DO NOT MODIFY THIS FILE DIRECTLY. IT IS AUTO-GENERATED BY .devcontainer/scripts/generate-configs.sh" > "$OUT_FILE"
|
||||
echo "" >> "$OUT_FILE"
|
||||
echo "# ---/Dockerfile---" >> "$OUT_FILE"
|
||||
|
||||
|
||||
@@ -29,6 +29,6 @@ echo "/usr/sbin/crond -c \"${SYSTEM_SERVICES_CROND}\" -f -L \"${LOG_CROND}\" >>\
|
||||
/usr/sbin/crond -c "${SYSTEM_SERVICES_CROND}" -f -L "${LOG_CROND}" >>"${LOG_CROND}" 2>&1 &
|
||||
crond_pid=$!
|
||||
|
||||
wait "${crond_pid}"
|
||||
wait "${crond_pid}"; status=$?
|
||||
echo -ne " done"
|
||||
exit $?
|
||||
exit ${status}
|
||||
|
||||
@@ -56,5 +56,6 @@ nginx \
|
||||
nginx_pid=$!
|
||||
|
||||
wait "${nginx_pid}"
|
||||
nginx_exit=$?
|
||||
echo -ne " done"
|
||||
exit $?
|
||||
exit ${nginx_exit}
|
||||
|
||||
@@ -24,8 +24,8 @@ done
|
||||
trap cleanup EXIT
|
||||
trap forward_signal INT TERM
|
||||
|
||||
echo "/usr/sbin/php-fpm83 -y \"${PHP_FPM_CONFIG_FILE}\" -F 2>&1 >>\"${LOG_APP_PHP_ERRORS}\" &"
|
||||
/usr/sbin/php-fpm83 -y "${PHP_FPM_CONFIG_FILE}" -F 2>&1 >>"${LOG_APP_PHP_ERRORS}" &
|
||||
echo "/usr/sbin/php-fpm83 -y \"${PHP_FPM_CONFIG_FILE}\" -F >>\"${LOG_APP_PHP_ERRORS}\" 2>&1 &"
|
||||
/usr/sbin/php-fpm83 -y "${PHP_FPM_CONFIG_FILE}" -F >>"${LOG_APP_PHP_ERRORS}" 2>&1 &
|
||||
php_fpm_pid=$!
|
||||
|
||||
wait "${php_fpm_pid}"
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
openwrt-luci-rpc
|
||||
asusrouter
|
||||
asyncio
|
||||
aiohttp
|
||||
graphene
|
||||
flask
|
||||
|
||||
Reference in New Issue
Block a user