diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 00000000..e8c061dc --- /dev/null +++ b/.dockerignore @@ -0,0 +1,6 @@ +/.nuxt +/.output +/node_modules + +.gitignore +README.md diff --git a/.env.example b/.env.example index d155e58d..8de24ba2 100644 --- a/.env.example +++ b/.env.example @@ -9,6 +9,8 @@ APP_HOST=http://localhost:3001/ # Contact form MAIL_HOST= +MAIL_PORT= +MAIL_SENDER= MAIL_USER= MAIL_PASSWORD= MAIL_RECEIVER= @@ -58,3 +60,7 @@ AXIOS_CACHE_TTL=0 # Available languages ​​in app ALLOWED_UI_LANGUAGES=pl,en DEFAULT_LANGUAGE=pl + +# Sentry +NUXT_PUBLIC_SENTRY_DSN= +NUXT_PUBLIC_SENTRY_ENVIRONMENT=development diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 03c7217a..3c0bef56 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -17,7 +17,7 @@ cache: # -------------------------- eslint: - image: node:16-alpine + image: node:18-alpine stage: test before_script: - yarn install @@ -27,7 +27,7 @@ eslint: - yarn lint:eslint vue-tsc: - image: node:16-alpine + image: node:18-alpine stage: test before_script: - yarn install @@ -41,15 +41,17 @@ vue-tsc: trigger-***REMOVED***-repo: stage: trigger rules: - - if: $CI_COMMIT_REF_NAME == $***REMOVED***_TRIGGER_BRANCH - when: always - - if: $CI_COMMIT_TAG - when: always + - if: $CI_COMMIT_REF_NAME == $***REMOVED***_TRIGGER_BRANCH + when: always + - if: $CI_COMMIT_TAG + when: always script: - if [ "$CI_COMMIT_TAG" != "" ]; then - export IMAGE_NAME=$CI_COMMIT_TAG; + export IMAGE_NAME=$CI_COMMIT_TAG; + export TARGET_BRANCH=$CI_COMMIT_TAG; else - export IMAGE_NAME=$***REMOVED***_IMAGE_NAME; + export IMAGE_NAME=$***REMOVED***_IMAGE_NAME; + export TARGET_BRANCH=$CI_COMMIT_BRANCH; fi - apt update -y && apt install -y curl - - curl -X POST -F token=$***REMOVED***_TRIGGER_TOKEN -F ref=main -F variables[IMAGE_NAME]=$IMAGE_NAME "***REMOVED***/api/v4/projects/929/trigger/pipeline" + - curl -X POST -F token=$***REMOVED***_TRIGGER_TOKEN -F ref=main -F variables[IMAGE_NAME]=$IMAGE_NAME -F variables[CI_BRANCH]=$TARGET_BRANCH "***REMOVED***/api/v4/projects/929/trigger/pipeline" diff --git a/Dockerfile b/Dockerfile index 8b6f34c4..a96dc239 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,11 +1,31 @@ -FROM node:18-alpine as builder +# syntax = docker/dockerfile:1 -EXPOSE 3000 +ARG NODE_VERSION=18.15.0 -WORKDIR /app -COPY / /app +FROM node:${NODE_VERSION}-slim as base + +ARG PORT=3000 + +ENV NODE_ENV=production + +WORKDIR /src + +# Build +FROM base as build + +COPY --link package.json yarn.lock ./ +RUN yarn install --production=false + +COPY --link . . -RUN yarn install RUN yarn build -CMD ["yarn", "start", "--hostname", "0.0.0.0"] +# Run +FROM base + +ENV PORT=$PORT +EXPOSE $PORT + +COPY --from=build /src/.output /src/.output + +CMD [ "node", ".output/server/index.mjs" ] diff --git a/Makefile b/Makefile new file mode 100644 index 00000000..c2ff8fdd --- /dev/null +++ b/Makefile @@ -0,0 +1,2 @@ +docker-compose: + docker compose up --build diff --git a/app.vue b/app.vue index 0db4dd2b..aba7b91f 100644 --- a/app.vue +++ b/app.vue @@ -1,6 +1,5 @@ + + diff --git a/components/address/List.vue b/components/address/List.vue index 82f0ce65..ea85cb99 100644 --- a/components/address/List.vue +++ b/components/address/List.vue @@ -55,7 +55,7 @@ diff --git a/components/home/BlogArticlesList.vue b/components/home/BlogArticlesList.vue index 32b3bcc8..24a7a824 100644 --- a/components/home/BlogArticlesList.vue +++ b/components/home/BlogArticlesList.vue @@ -13,7 +13,7 @@ @@ -21,10 +21,12 @@ diff --git a/components/home/ImageCarousel.vue b/components/home/ImageCarousel.vue index ccdd19aa..893c1f9f 100644 --- a/components/home/ImageCarousel.vue +++ b/components/home/ImageCarousel.vue @@ -4,7 +4,7 @@ {{ banner.name }} - - -{ - "pl": { - "expand": "Rozwiń", - "collapse": "Zwiń" - }, - "en": { - "expand": "Expand", - "collapse": "Collapse" - } -} - - diff --git a/components/product/page/Banner.vue b/components/product/page/Banner.vue new file mode 100644 index 00000000..c21c1c5d --- /dev/null +++ b/components/product/page/Banner.vue @@ -0,0 +1,51 @@ + + + + + diff --git a/components/product/page/ContactForm.vue b/components/product/page/ContactForm.vue index 13daf9e4..b15afacb 100644 --- a/components/product/page/ContactForm.vue +++ b/components/product/page/ContactForm.vue @@ -1,5 +1,6 @@