forked from VILLASframework/controller
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
32 lines (23 loc) · 746 Bytes
/
Dockerfile
File metadata and controls
32 lines (23 loc) · 746 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# SPDX-FileCopyrightText: 2014-2025 The VILLASframework Authors
# SPDX-License-Identifier: Apache-2.0
# Build stage
FROM python:3.13 AS builder
RUN apt-get update && apt-get install -y --no-install-recommends \
build-essential gcc python3-dev pkg-config && \
rm -rf /var/lib/apt/lists/*
RUN pip install --upgrade \
pip \
setuptools \
wheel \
build
WORKDIR /build
COPY . .
RUN python -m build && \
pip install dist/*.tar.gz --prefix=/install
# Runtime stage
FROM python:3.13-slim AS runtime
# Copy installed Python libs + CLI scripts
COPY --from=builder /install /usr/local
COPY etc/*.json etc/*.yaml /etc/villas/controller/
COPY villas-controller.service /etc/systemd/system/
ENTRYPOINT ["villas-controller"]