Skip to content

Commit

Permalink
🚨(docker) fix docker warning about casing
Browse files Browse the repository at this point in the history
When we build the docker image, we get a warning
about the casing in the Dockerfile. This commit
fixes the casing in the Dockerfile.
  • Loading branch information
AntoLC committed Oct 14, 2024
1 parent 52eb973 commit 97d00b6
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
14 changes: 7 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Django impress

# ---- base image to inherit from ----
FROM python:3.12.6-alpine3.20 as base
FROM python:3.12.6-alpine3.20 AS base

# Upgrade pip to its latest release to speed up dependencies installation
RUN python -m pip install --upgrade pip setuptools
Expand All @@ -11,7 +11,7 @@ RUN apk update && \
apk upgrade

# ---- Back-end builder image ----
FROM base as back-builder
FROM base AS back-builder

WORKDIR /builder

Expand All @@ -23,7 +23,7 @@ RUN mkdir /install && \


# ---- mails ----
FROM node:20 as mail-builder
FROM node:20 AS mail-builder

COPY ./src/mail /mail/app

Expand All @@ -34,7 +34,7 @@ RUN yarn install --frozen-lockfile && \


# ---- static link collector ----
FROM base as link-collector
FROM base AS link-collector
ARG IMPRESS_STATIC_ROOT=/data/static

# Install pango & rdfind
Expand All @@ -59,7 +59,7 @@ RUN DJANGO_CONFIGURATION=Build DJANGO_JWT_PRIVATE_SIGNING_KEY=Dummy \
RUN rdfind -makesymlinks true -followsymlinks true -makeresultsfile false ${IMPRESS_STATIC_ROOT}

# ---- Core application image ----
FROM base as core
FROM base AS core

ENV PYTHONUNBUFFERED=1

Expand Down Expand Up @@ -97,7 +97,7 @@ WORKDIR /app
ENTRYPOINT [ "/usr/local/bin/entrypoint" ]

# ---- Development image ----
FROM core as backend-development
FROM core AS backend-development

# Switch back to the root user to install development dependencies
USER root:root
Expand All @@ -123,7 +123,7 @@ ENV DB_HOST=postgresql \
CMD ["python", "manage.py", "runserver", "0.0.0.0:8000"]

# ---- Production image ----
FROM core as backend-production
FROM core AS backend-production

ARG IMPRESS_STATIC_ROOT=/data/static

Expand Down
14 changes: 7 additions & 7 deletions src/frontend/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:20-alpine as frontend-deps-y-provider
FROM node:20-alpine AS frontend-deps-y-provider

WORKDIR /home/frontend/

Expand All @@ -15,7 +15,7 @@ COPY ./src/frontend/ .
COPY ./docker/files/usr/local/bin/entrypoint /usr/local/bin/entrypoint

# ---- y-provider ----
FROM frontend-deps-y-provider as y-provider
FROM frontend-deps-y-provider AS y-provider

WORKDIR /home/frontend/servers/y-provider
RUN yarn build
Expand All @@ -28,7 +28,7 @@ ENTRYPOINT [ "/usr/local/bin/entrypoint" ]

CMD ["yarn", "start"]

FROM node:20-alpine as frontend-deps
FROM node:20-alpine AS frontend-deps

WORKDIR /home/frontend/

Expand All @@ -43,11 +43,11 @@ COPY .dockerignore ./.dockerignore
COPY ./src/frontend/ .

### ---- Front-end builder image ----
FROM frontend-deps as impress
FROM frontend-deps AS impress

WORKDIR /home/frontend/apps/impress

FROM frontend-deps as impress-dev
FROM frontend-deps AS impress-dev

WORKDIR /home/frontend/apps/impress

Expand All @@ -57,7 +57,7 @@ CMD [ "yarn", "dev"]

# Tilt will rebuild impress target so, we dissociate impress and impress-builder
# to avoid rebuilding the app at every changes.
FROM impress as impress-builder
FROM impress AS impress-builder

WORKDIR /home/frontend/apps/impress

Expand All @@ -79,7 +79,7 @@ ENV NEXT_PUBLIC_SW_DEACTIVATED=${SW_DEACTIVATED}
RUN yarn build

# ---- Front-end image ----
FROM nginxinc/nginx-unprivileged:1.26-alpine as frontend-production
FROM nginxinc/nginx-unprivileged:1.26-alpine AS frontend-production

# Un-privileged user running the application
ARG DOCKER_USER
Expand Down

0 comments on commit 97d00b6

Please sign in to comment.