diff --git a/.dockerignore b/.dockerignore index 11cc0bbce0..cbc18c6cee 100644 --- a/.dockerignore +++ b/.dockerignore @@ -3,6 +3,9 @@ node_modules npm-debug.log .git .gitignore +.devcontainer/ +.github/ +.vscode/ /config /audiobooks /audiobooks2 @@ -11,6 +14,8 @@ npm-debug.log dev.js test/ /client/.nuxt/ +/client/.output/ /client/dist/ /dist/ +/build/ /deploy/ \ No newline at end of file diff --git a/.github/workflows/integration-test.yml b/.github/workflows/integration-test.yml index f88db2ed13..ceefc3b3eb 100644 --- a/.github/workflows/integration-test.yml +++ b/.github/workflows/integration-test.yml @@ -13,7 +13,7 @@ jobs: steps: - uses: actions/checkout@v3 - - name: setup nade + - name: setup node uses: actions/setup-node@v3 with: node-version: 16 @@ -27,7 +27,7 @@ jobs: - name: build client working-directory: client - run: npm run generate + run: npm run build - name: get server dependencies run: npm ci --only=production diff --git a/.gitignore b/.gitignore index 25a8a77460..239b9544b8 100644 --- a/.gitignore +++ b/.gitignore @@ -9,6 +9,7 @@ /metadata/ test/ /client/.nuxt/ +/client/.output/ /client/dist/ /dist/ /deploy/ diff --git a/Dockerfile b/Dockerfile index fe2e005981..ad37167761 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,14 +1,19 @@ ### STAGE 0: Build client ### FROM node:16-alpine AS build WORKDIR /client -COPY /client /client + +COPY /client/package*.json /client/ RUN npm ci && npm cache clean --force -RUN npm run generate + +COPY /client /client +RUN npm run build ### STAGE 1: Build server ### FROM sandreas/tone:v0.1.5 AS tone FROM node:16-alpine +WORKDIR /app + ENV NODE_ENV=production RUN apk update && \ apk add --no-cache --update \ @@ -17,11 +22,13 @@ RUN apk update && \ ffmpeg COPY --from=tone /usr/local/bin/tone /usr/local/bin/ -COPY --from=build /client/dist /client/dist -COPY index.js package* / -COPY server server +COPY package* ./ -RUN npm ci --only=production +RUN npm ci --omit=dev + +COPY index.js package* ./ +COPY server server +COPY --from=build /client/.output ./client/.output EXPOSE 80 HEALTHCHECK \ diff --git a/client/assets/app.css b/client/assets/app.css index f8e515212d..cc9e59f911 100644 --- a/client/assets/app.css +++ b/client/assets/app.css @@ -5,7 +5,7 @@ @import './absicons.css'; :root { - --bookshelf-texture-img: url(/textures/wood_default.jpg); + --bookshelf-texture-img: url(~static/textures/wood_default.jpg); --bookshelf-divider-bg: linear-gradient(180deg, rgba(149, 119, 90, 1) 0%, rgba(103, 70, 37, 1) 17%, rgba(103, 70, 37, 1) 88%, rgba(71, 48, 25, 1) 100%); } diff --git a/client/components/app/ConfigSideNav.vue b/client/components/app/ConfigSideNav.vue index af4645f4bb..52565060b4 100644 --- a/client/components/app/ConfigSideNav.vue +++ b/client/components/app/ConfigSideNav.vue @@ -10,12 +10,12 @@
-v{{ $config.version }}
+v{{ $config.public.version }}
{{ Source }}
v{{ $config.public.version }}
+ Update +{{ Source }}
+