-
-
Notifications
You must be signed in to change notification settings - Fork 6
/
Dockerfile
49 lines (36 loc) · 1.12 KB
/
Dockerfile
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# <--- Pre-Build Args -->
ARG BUILD_ARCH
# <--- Main Image -->
FROM python:3.10-slim-bullseye
WORKDIR /app
# <--- Post-Build Args -->
ARG BUILD_VERSION
# <--- Environment Variables -->
ENV BUILD_VERSION $BUILD_VERSION
ENV BUILD_ARCH $BUILD_ARCH
# <--- System Wide Dependencies -->
ENV LANG C.UTF-8
RUN apt-get update -y && \
apt-get install -y gcc git build-essential libtool automake curl
# <--- Scripts -->
COPY docker/bin /app/bin
COPY docker/hypercorn.toml /app/hypercorn.toml
# <--- PREP -->
RUN /app/bin/prep.sh
# <--- Python Dependencies -->
COPY api/setup.py /app/setup.py
# <--- BUILD -->
RUN /app/bin/build.sh /app
# <--- Api Code -->
COPY api/src /app/src
COPY webapp/build /app/web
# <--- Ports -->
EXPOSE 8000
# <--- Final -->
LABEL \
io.hass.type="addon" \
io.hass.arch="armhf|aarch64|i386|amd64|armv7"
ENTRYPOINT [ "/app/bin/run.sh" ]
CMD [ "/app" ]
LABEL org.opencontainers.image.source https://github.com/asosnovsky/Shortumation
LABEL org.opencontainers.image.description "A better way to write automations in home-assistant without having to install and run a seperate automation engine!"