generated from BrewBlox/brewblox-boilerplate
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #30 from BrewBlox/develop
Edge release
- Loading branch information
Showing
15 changed files
with
642 additions
and
696 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
.venv/ | ||
.vscode/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
FROM python:3.11-bookworm as base | ||
|
||
ENV PIP_EXTRA_INDEX_URL=https://www.piwheels.org/simple | ||
ENV PIP_FIND_LINKS=/wheeley | ||
ENV VENV=/app/.venv | ||
ENV PATH="$VENV/bin:$PATH" | ||
|
||
COPY ./dist /app/dist | ||
|
||
RUN <<EOF | ||
set -ex | ||
|
||
mkdir /wheeley | ||
python3 -m venv $VENV | ||
pip3 install --upgrade pip wheel setuptools | ||
pip3 wheel --wheel-dir=/wheeley -r /app/dist/requirements.txt | ||
pip3 wheel --wheel-dir=/wheeley /app/dist/*.tar.gz | ||
EOF | ||
|
||
FROM python:3.11-slim-bookworm | ||
EXPOSE 5000 | ||
WORKDIR /app | ||
|
||
ENV PIP_FIND_LINKS=/wheeley | ||
ENV VENV=/app/.venv | ||
ENV PATH="$VENV/bin:$PATH" | ||
|
||
COPY --from=base /wheeley /wheeley | ||
|
||
RUN <<EOF | ||
set -ex | ||
|
||
python3 -m venv $VENV | ||
pip3 install --no-index brewblox_hass | ||
pip3 freeze | ||
rm -rf /wheeley | ||
EOF | ||
|
||
ENTRYPOINT ["python3", "-m", "brewblox_hass"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
from typing import Optional | ||
|
||
from brewblox_service.models import BaseServiceConfig, MqttProtocol | ||
|
||
|
||
class ServiceConfig(BaseServiceConfig): | ||
hass_mqtt_protocol: MqttProtocol | ||
hass_mqtt_host: str | ||
hass_mqtt_port: Optional[int] | ||
hass_mqtt_path: str |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.