Skip to content

Commit

Permalink
Test uv
Browse files Browse the repository at this point in the history
  • Loading branch information
robbibt authored Sep 2, 2024
1 parent 4d8b199 commit fe926da
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 27 deletions.
38 changes: 13 additions & 25 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,38 +12,26 @@ ENV DEBIAN_FRONTEND=noninteractive \
RUN apt-get update && \
apt-get install -y \
build-essential \
fish \
git \
vim \
htop \
wget \
unzip \
python3-pip \
libpq-dev \
&& apt-get autoclean && \
apt-get autoremove && \
rm -rf /var/lib/{apt,dpkg,cache,log}

# Install pip-tools
RUN pip install pip-tools
# Set up working directory and copy in code
WORKDIR /app
COPY . .

# Pip installation
RUN mkdir -p /conf
# COPY requirements.in /conf/
# RUN pip-compile --extra-index-url=https://packages.dea.ga.gov.au/ --output-file=/conf/requirements.txt /conf/requirements.in
COPY requirements.txt /conf/
RUN pip install -r /conf/requirements.txt \
&& pip install --no-cache-dir awscli==1.33.37
# Install requirements
RUN pip install uv && \
uv pip compile requirements.in -o requirements.txt && \
uv pip install -r requirements.txt --system

# Copy source code and install it
RUN mkdir -p /code
WORKDIR /code
ADD . /code
# Install DEA Intertidal and verify installation
RUN uv pip install . --system && \
uv pip check && \
dea-intertidal --help

RUN echo "Installing dea-intertidal through the Dockerfile."
RUN pip install --extra-index-url="https://packages.dea.ga.gov.au" .

RUN pip freeze && pip check

# Make sure it's working
RUN dea-intertidal --help
# Set the entrypoint to dea-intertidal
ENTRYPOINT ["dea-intertidal"]
4 changes: 2 additions & 2 deletions requirements.in
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
--extra-index-url=https://packages.dea.ga.gov.au/
aiohttp
awscli==1.33.37
botocore
click==8.1.7
datacube[s3,performance]==1.8.18
Expand Down Expand Up @@ -30,4 +30,4 @@ sunriset==1.0
shapely==2.0.1
tqdm==4.66.2
xarray==2024.3.0
xskillscore==0.0.24
xskillscore==0.0.24

0 comments on commit fe926da

Please sign in to comment.