Self hosted FLOSS fitness/workout, nutrition and weight tracker
More cleanup and making sure node files are copied over to the static folder
Roland Geider908f8e714784
diff --git a/extras/docker/development/Dockerfile b/extras/docker/development/Dockerfileindex 3f9894135..651006474 100644--- a/extras/docker/development/Dockerfile+++ b/extras/docker/development/Dockerfile@@ -9,11 +9,12 @@ FROM wger/server:latestUSER rootWORKDIR /home/wger/src-RUN apt-get update && \- apt-get install --no-install-recommends -y \+RUN wget -O- https://deb.nodesource.com/setup_22.x | bash - \+ apt update && \+ apt install --no-install-recommends -y \git \vim \- yarnpkg \+ nodejs \sassc \&& apt-get clean \&& rm -rf /var/lib/apt/lists/* \@@ -22,6 +23,6 @@ RUN apt-get update && \USER wgerCOPY --chown=wger:wger . /home/wger/src-RUN yarn install \+RUN yarn install:force \&& yarn build:css:sass \&& pip3 install --break-system-packages --user --group dev --editable .diff --git a/extras/docker/production/Dockerfile b/extras/docker/production/Dockerfileindex 5d7aca114..af228ae78 100644--- a/extras/docker/production/Dockerfile+++ b/extras/docker/production/Dockerfile@@ -41,14 +41,11 @@ RUN wget -O- https://deb.nodesource.com/setup_22.x | bash - \#WORKDIR /root/src-# Copy necessary files to build the application+# Build the applicationCOPY pyproject.toml /root/srcCOPY wger/version.py /root/src/wger/COPY wger/__init__.py /root/src/wger/COPY README.md /root/src-COPY package.json /root/src-COPY yarn.lock /root/src-COPY wger/core/static /root/src/wger/core/static# NB: the --mount tmpfs is a workaround for https://github.com/rust-lang/cargo/issues/8719RUN --mount=type=tmpfs,target=/root/.cargo \@@ -58,11 +55,10 @@ RUN --mount=type=tmpfs,target=/root/.cargo \--group docker . \&& ln -s /usr/bin/sassc /usr/bin/sass-## Build the JS and CSS files-#-RUN yarn config set nodeLinker node-modules \- && yarn install \+COPY package.json yarn.lock .yarnrc.yml ./+COPY wger/core/static /root/src/wger/core/static+RUN yarn install \&& yarn build:css:sass \&& cd .. \&& wget https://github.com/wger-project/react/archive/refs/heads/master.zip \diff --git a/package.json b/package.jsonindex 8500079c6..fbe7a2343 100644--- a/package.json+++ b/package.json@@ -3,7 +3,7 @@"version": "2.4.alpha1","description": "Self hosted FLOSS fitness/workout and weight tracker","repository": "github:wger-project/wger",- "author": "",+ "author": "wger team <[email protected]>","license": "AGPL-3.0","bugs": {"url": "https://github.com/wger-project/wger/issues"@@ -22,7 +22,7 @@},"scripts": {"build:css:sass": "sass wger/core/static/scss/main.scss wger/core/static/yarn/bootstrap-compiled.css",- "install": "yarn install && yarn run postinstall",+ "install:force": "yarn install && yarn run postinstall","postinstall": "rm -rf wger/core/static/yarn/ && mkdir -p wger/core/static/yarn/ && cp -r node_modules/* wger/core/static/yarn/"},"engines": {