diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000000000000000000000000000000000000..07bd325af541115e994d3ab5a27c821eb1c173a1 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,32 @@ +# Create container for building stt-frontend +FROM node:16.14.0-alpine as build + +RUN mkdir -p /usr/app +WORKDIR /usr/app + +RUN apk add --no-cache git +RUN apk add --update --no-cache \ + make \ + g++ \ + jpeg-dev \ + cairo-dev \ + giflib-dev \ + pango-dev \ + libtool \ + autoconf \ + automake + +COPY . . + +RUN npm i --prefix addons/storyTellingTool +RUN npm i --prefix + +RUN npm run buildPortal --prefix + +# Create container for running stt-frontend +FROM nginx + +# Copy build files from build container +COPY --from=build /usr/app/dist /usr/share/nginx/html + +EXPOSE 80 diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000000000000000000000000000000000000..01ea6573bfe3e677299e14d348aba613d013f9ff --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,14 @@ +version: '3.9' +services: + # Frontend incl. Masterportal configuration for the storytelling tool + stt-frontend: + container_name: stt-frontend + build: + context: . + dockerfile: Dockerfile + networks: + - proxy + +networks: + proxy: + external: true