mirror of
https://github.com/openmhz/trunk-server.git
synced 2026-11-09 15:27:30 -05:00
fixed up
This commit is contained in:
@@ -10,7 +10,7 @@ ARG REACT_APP_SITE_NAME
|
||||
ARG REACT_APP_ADMIN_EMAIL
|
||||
ARG NODE_ENV
|
||||
COPY package.json ./
|
||||
RUN npm install --also=dev
|
||||
RUN npm install --include=dev
|
||||
COPY . ./
|
||||
RUN npm run build
|
||||
RUN env
|
||||
|
||||
@@ -10,7 +10,7 @@ ARG REACT_APP_SITE_NAME
|
||||
ARG REACT_APP_ADMIN_EMAIL
|
||||
ARG NODE_ENV
|
||||
COPY package.json ./
|
||||
RUN npm install --also=dev
|
||||
RUN npm install --include=dev
|
||||
COPY . ./
|
||||
RUN npm run build
|
||||
|
||||
|
||||
@@ -181,7 +181,3 @@ services:
|
||||
driver: syslog
|
||||
options:
|
||||
tag: "frontend"
|
||||
|
||||
networks:
|
||||
proxy:
|
||||
node:
|
||||
|
||||
@@ -8,7 +8,7 @@ ARG REACT_APP_FRONTEND_SERVER
|
||||
ARG REACT_APP_GOOGLE_ANALYTICS
|
||||
ARG NODE_ENV
|
||||
COPY package.json ./
|
||||
RUN npm install --also=dev
|
||||
RUN npm install --include=dev
|
||||
COPY . ./
|
||||
RUN npm run build
|
||||
|
||||
|
||||
@@ -10,12 +10,12 @@ fi
|
||||
|
||||
# Rest of the script...
|
||||
|
||||
if ! [ -x "$(command -v docker-compose)" ]; then
|
||||
echo 'Error: docker-compose is not installed.' >&2
|
||||
if ! [ -x "$(command -v docker compose)" ]; then
|
||||
echo 'Error: docker compose is not installed.' >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
domains=($REACT_APP_FRONTEND_SERVER, $REACT_APP_BACKEND_SERVER, "https://socket.${DOMAIN_NAME}", $REACT_APP_ACCOUNT_SERVER, $REACT_APP_ADMIN_SERVER)
|
||||
domains=("$DOMAIN_NAME" "account.$DOMAIN_NAME" "admin.$DOMAIN_NAME" "api.$DOMAIN_NAME")
|
||||
|
||||
rsa_key_size=4096
|
||||
data_path="./data/certbot"
|
||||
@@ -41,7 +41,7 @@ fi
|
||||
echo "### Creating dummy certificate for $domains ..."
|
||||
path="/etc/letsencrypt/live/$domains"
|
||||
mkdir -p "$data_path/conf/live/$domains"
|
||||
docker-compose run --rm --entrypoint "\
|
||||
docker compose run --rm --entrypoint "\
|
||||
openssl req -x509 -nodes -newkey rsa:$rsa_key_size -days 1\
|
||||
-keyout '$path/privkey.pem' \
|
||||
-out '$path/fullchain.pem' \
|
||||
@@ -50,11 +50,11 @@ echo
|
||||
|
||||
|
||||
echo "### Starting nginx ..."
|
||||
docker-compose up --force-recreate -d nginx
|
||||
docker compose up -d nginx
|
||||
echo
|
||||
|
||||
echo "### Deleting dummy certificate for $domains ..."
|
||||
docker-compose run --rm --entrypoint "\
|
||||
docker compose run --rm --entrypoint "\
|
||||
rm -Rf /etc/letsencrypt/live/$domains && \
|
||||
rm -Rf /etc/letsencrypt/archive/$domains && \
|
||||
rm -Rf /etc/letsencrypt/renewal/$domains.conf" certbot
|
||||
@@ -77,7 +77,7 @@ esac
|
||||
# Enable staging mode if needed
|
||||
if [ $staging != "0" ]; then staging_arg="--staging"; fi
|
||||
|
||||
docker-compose run --rm --entrypoint "\
|
||||
docker compose run --rm --entrypoint "\
|
||||
certbot certonly --webroot -w /var/www/certbot \
|
||||
$staging_arg \
|
||||
$email_arg \
|
||||
@@ -88,4 +88,4 @@ docker-compose run --rm --entrypoint "\
|
||||
echo
|
||||
|
||||
echo "### Reloading nginx ..."
|
||||
docker-compose exec nginx nginx -s reload
|
||||
docker compose exec nginx nginx -s reload
|
||||
Reference in New Issue
Block a user