Skip to content

Commit

Permalink
Tweak deployment replicas and requests.
Browse files Browse the repository at this point in the history
  • Loading branch information
ropable committed Jul 17, 2024
1 parent 13172c0 commit 905f2ce
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
12 changes: 6 additions & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
# syntax=docker/dockerfile:1
# Prepare the base environment.
FROM python:3.11.9-slim as builder_base_mapproxy
MAINTAINER [email protected]
LABEL org.opencontainers.image.source https://github.com/dbca-wa/mapproxy
FROM python:3.11.9-slim AS builder_base_mapproxy
LABEL org.opencontainers.image.authors=[email protected]
LABEL org.opencontainers.image.source=https://github.com/dbca-wa/mapproxy

RUN apt-get update -y \
&& apt-get upgrade -y \
&& apt-get install --no-install-recommends -y libgeos-dev libgdal-dev \
&& rm -rf /var/lib/apt/lists/* \
&& pip install --upgrade pip
&& pip install --root-user-action=ignore --upgrade pip

# Install Python libs using Poetry.
FROM builder_base_mapproxy as python_libs_mapproxy
FROM builder_base_mapproxy AS python_libs_mapproxy
WORKDIR /app
ARG POETRY_VERSION=1.8.3
RUN pip install poetry=="${POETRY_VERSION}"
RUN pip install --root-user-action=ignore poetry=="${POETRY_VERSION}"
COPY poetry.lock pyproject.toml ./
RUN poetry config virtualenvs.create false \
&& poetry install --no-interaction --no-ansi --only main
Expand Down
4 changes: 2 additions & 2 deletions kustomize/base/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ spec:
value: "Australia/Perth"
resources:
requests:
memory: "200Mi"
cpu: "50m"
memory: "100Mi"
cpu: "5m"
limits:
memory: "2Gi"
cpu: "1000m"
Expand Down
4 changes: 2 additions & 2 deletions kustomize/base/deployment_hpa.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ kind: HorizontalPodAutoscaler
metadata:
name: mapproxy-deployment-hpa
spec:
minReplicas: 1
maxReplicas: 3
minReplicas: 2
maxReplicas: 10
scaleTargetRef:
apiVersion: apps/v1
kind: Deployment
Expand Down

0 comments on commit 905f2ce

Please sign in to comment.