diff --git a/docker-compose.yaml.example b/docker-compose.yaml.example index 258f640..10ce264 100644 --- a/docker-compose.yaml.example +++ b/docker-compose.yaml.example @@ -14,13 +14,14 @@ networks: services: nodejs: - image: ${IMAGE_BASE}/nodejs:18.17.0 + image: ${IMAGE_BASE}/nodejs:18.18.2 container_name: nodejs environment: - PACKAGE_PATH=${PACKAGE_PATH} volumes: - "${WWWROOT_PATH}:/data/wwwroot" working_dir: /data/wwwroot/ + privileged: true networks: aix-docker-cc: ipv4_address: ${NET_SUBNET:-10.12.25}.200 diff --git a/nodejs/entrypoint.sh b/nodejs/entrypoint.sh index b72bf2c..2394d28 100644 --- a/nodejs/entrypoint.sh +++ b/nodejs/entrypoint.sh @@ -1,3 +1,2 @@ #!/bin/bash -npm install -npm run production +cnpm -v diff --git a/nodejs/run-script.sh b/nodejs/run-script.sh new file mode 100644 index 0000000..e756f38 --- /dev/null +++ b/nodejs/run-script.sh @@ -0,0 +1,2 @@ +#!/bin/bash +pwd \ No newline at end of file diff --git a/www/run-script.sh b/www/run-script.sh new file mode 100644 index 0000000..5b33d92 --- /dev/null +++ b/www/run-script.sh @@ -0,0 +1,4 @@ +#!/bin/bash +cd /data/wwwroot/项目 +npm install +npm run build \ No newline at end of file