Skip to content

Commit

Permalink
Update dockerfile and pyproject
Browse files Browse the repository at this point in the history
  • Loading branch information
tsundvoll authored and aeshub committed Feb 8, 2023
1 parent aa46889 commit 932a92e
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 15 deletions.
8 changes: 7 additions & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
@@ -1 +1,7 @@
venv
*
!src/isar_robot
!setup.py
!setup.cfg
!pyproject.toml
!README.md
!LICENSE
15 changes: 8 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
FROM ghcr.io/equinor/isar:latest
FROM python:3.10-slim as builder

ARG ROBOT_REPOSITORY_CLONE_URL=https://github.com/equinor/isar-robot.git
RUN python -m venv --copies /opt/venv
ENV PATH="/opt/venv/bin:$PATH"

RUN pip install git+${ROBOT_REPOSITORY_CLONE_URL}@main
COPY . .
RUN pip install .

RUN useradd -ms /bin/bash --uid 1001 isar
RUN chown -R 1001 /app
RUN chmod 755 /app
USER 1001
FROM ghcr.io/equinor/isar:latest
COPY --from=builder /opt/venv /opt/venv
ENV PATH="/opt/venv/bin:$PATH"
8 changes: 1 addition & 7 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,3 @@
[build-system]
requires = [
"setuptools>=42",
"wheel",
"setuptools_scm>=6.2"
]
requires = ["setuptools>=61.0"]
build-backend = "setuptools.build_meta"

[tool.setuptools_scm]

0 comments on commit 932a92e

Please sign in to comment.