Kaynağa Gözat

Update Dockerfile

pull/544/head
Guillaume Vincent 4 yıl önce
ebeveyn
işleme
c8361afd73
5 değiştirilmiş dosya ile 25 ekleme ve 24 silme
  1. +6
    -13
      containers/backend/Dockerfile
  2. +13
    -0
      containers/blog/Dockerfile
  3. +1
    -1
      containers/docker-compose.yml
  4. +1
    -6
      containers/webserver/Dockerfile
  5. +4
    -4
      packages/lesspass-site/Dockerfile

+ 6
- 13
containers/backend/Dockerfile Dosyayı Görüntüle

@@ -1,20 +1,13 @@
FROM python:3.6

MAINTAINER "LessPass <contact@lesspass.com>"

LABEL maintainer="LessPass <contact@lesspass.com>"
LABEL name="LessPass Backend"

RUN mkdir /app
WORKDIR /app
COPY requirements.txt /app
RUN mkdir /opt/backend
WORKDIR /opt/backend
COPY requirements.txt /opt/backend
RUN python -m pip install --upgrade pip
RUN python -m pip install -r requirements.txt

COPY . /app
COPY . /opt/backend
RUN python --version

EXPOSE 8000

ENTRYPOINT ["/app/entrypoint.sh"]

ENTRYPOINT ["/opt/backend/entrypoint.sh"]
CMD ["gunicorn", "lesspass.wsgi:application", "--access-logfile", "-", "--error-logfile", "-", "--log-level", "debug", "--bind", "0.0.0.0:8000"]

+ 13
- 0
containers/blog/Dockerfile Dosyayı Görüntüle

@@ -0,0 +1,13 @@
FROM node:lts AS builder
LABEL maintainer="LessPass <contact@lesspass.com>"
LABEL name="LessPass Blog"
WORKDIR /opt/blog
COPY package.json yarn.lock ./
RUN yarn install
COPY . /opt/blog
RUN yarn build
FROM nginx:alpine
COPY --from=builder /opt/blog/build /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]

+ 1
- 1
containers/docker-compose.yml Dosyayı Görüntüle

@@ -2,7 +2,7 @@ version: "3"
services:
db:
restart: always
image: postgres:10
image: postgres:9.5
volumes:
- postgresql:/var/lib/postgresql/data
environment:


+ 1
- 6
containers/webserver/Dockerfile Dosyayı Görüntüle

@@ -1,13 +1,8 @@
FROM httpd:2.4

MAINTAINER "LessPass <contact@lesspass.com>"

LABEL maintainer="LessPass <contact@lesspass.com>"
LABEL name="LessPass Web Server"

COPY ./httpd.conf /usr/local/apache2/conf/httpd.conf
COPY ./httpd-ssl.conf /usr/local/apache2/conf/extra/httpd-ssl.conf
COPY entrypoint.sh /entrypoint.sh

ENTRYPOINT ["/entrypoint.sh"]

CMD ["httpd-foreground"]

+ 4
- 4
packages/lesspass-site/Dockerfile Dosyayı Görüntüle

@@ -1,13 +1,13 @@
FROM node:lts AS builder
MAINTAINER "LessPass <contact@lesspass.com>"
LABEL maintainer="LessPass <contact@lesspass.com>"
LABEL name="LessPass Frontend"
WORKDIR /frontend
WORKDIR /opt/frontend
COPY package.json yarn.lock ./
RUN yarn install
COPY . /frontend
COPY . /opt/frontend
RUN yarn build
FROM nginx:alpine
COPY --from=builder /frontend/build /usr/share/nginx/html
COPY --from=builder /opt/frontend/build /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]

Yükleniyor…
İptal
Kaydet