Skip to content

Commit

Permalink
Remove comments on dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
kshitijrajsharma committed Feb 15, 2024
1 parent c8d32f5 commit fbb4c1b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 21 deletions.
17 changes: 5 additions & 12 deletions backend/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,38 +1,31 @@
# Use a specific base image with GPU support
FROM tensorflow/tensorflow:2.9.2-gpu

# Update package lists and install necessary dependencies in a single step
RUN apt-get update && \
apt-get install -y python3-opencv gdal-bin libgdal-dev && \
add-apt-repository ppa:ubuntugis/ppa && \
apt-get update && \
rm -rf /var/lib/apt/lists/*

# Set environment variables for GDAL
ENV CPLUS_INCLUDE_PATH=/usr/include/gdal
ENV C_INCLUDE_PATH=/usr/include/gdal

# Install specific version of NumPy
RUN pip install numpy==1.23.5

# Install GDAL with specified options
RUN pip install numpy==1.23.5
RUN pip install --global-option=build_ext --global-option="-I/usr/include/gdal" GDAL==$(gdal-config --version)

# Copy and install Python requirements

COPY docker/ramp/docker-requirements.txt /tmp/docker-requirements.txt
RUN pip install -r /tmp/docker-requirements.txt

# Upgrade setuptools
RUN pip install --upgrade setuptools

RUN pip install --upgrade setuptools
COPY requirements.txt /tmp/requirements.txt
RUN pip install -r /tmp/requirements.txt

# Install solaris and scikit-fmm packages

COPY docker/ramp/solaris /tmp/solaris
RUN pip install /tmp/solaris --use-feature=in-tree-build && \
pip install scikit-fmm --use-feature=in-tree-build

# Set working directory and copy the application code

WORKDIR /app
COPY . /app
11 changes: 2 additions & 9 deletions backend/Dockerfile_CPU
Original file line number Diff line number Diff line change
@@ -1,35 +1,28 @@
# Use a specific base image with the desired TensorFlow version
FROM tensorflow/tensorflow:2.9.2

# Update package lists and install necessary dependencies in a single step
RUN apt-get update && \
apt-get install -y software-properties-common python3-opencv && \
add-apt-repository ppa:ubuntugis/ppa && \
apt-get update && \
apt-get install -y gdal-bin libgdal-dev && \
rm -rf /var/lib/apt/lists/*

# Set environment variables for GDAL
ENV CPLUS_INCLUDE_PATH=/usr/include/gdal
ENV C_INCLUDE_PATH=/usr/include/gdal

# Install specific version of NumPy
RUN pip install numpy==1.23.5

# Install GDAL with specified options
RUN pip install --global-option=build_ext --global-option="-I/usr/include/gdal" GDAL==$(gdal-config --version)

# Copy and install Python requirements

COPY docker/ramp/docker-requirements.txt /tmp/docker-requirements.txt
RUN pip install -r /tmp/docker-requirements.txt

# Upgrade setuptools

RUN pip install --upgrade setuptools

COPY requirements.txt /tmp/requirements.txt
RUN pip install -r /tmp/requirements.txt

# Install solaris and scikit-fmm packages
COPY docker/ramp/solaris /tmp/solaris
RUN pip install /tmp/solaris --use-feature=in-tree-build && \
pip install scikit-fmm --use-feature=in-tree-build
Expand Down

0 comments on commit fbb4c1b

Please sign in to comment.