From 28c5568d0791d04abd92ecd106f123a9e41d7453 Mon Sep 17 00:00:00 2001 From: Ben Kristinsson Date: Thu, 23 Mar 2023 17:13:39 +0100 Subject: [PATCH 1/4] basic dockerfile pulling upstream image and adding cups packages and gcc --- hass/Dockerfile | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 hass/Dockerfile diff --git a/hass/Dockerfile b/hass/Dockerfile new file mode 100644 index 0000000..4a7c9b7 --- /dev/null +++ b/hass/Dockerfile @@ -0,0 +1,8 @@ +# clone hass repo, build their Dockerfile +# "stable" is probably a branch + +FROM ghcr.io/home-assistant/home-assistant:stable + +RUN apk add python3-dev cups-dev gcc + +ENTRYPOINT /init -- 2.40.1 From 2a90185ccef79a1da3d429af29b4ae453c1bb82b Mon Sep 17 00:00:00 2001 From: Ben Kristinsson Date: Thu, 23 Mar 2023 17:16:24 +0100 Subject: [PATCH 2/4] adding the needed build pipelien boilerplate --- .gitignore | 2 -- hass/.dockerignore | 2 ++ hass/.gitignore | 1 + hass/.pipeline/empty.env | 0 4 files changed, 3 insertions(+), 2 deletions(-) create mode 100644 hass/.dockerignore create mode 100644 hass/.gitignore create mode 100644 hass/.pipeline/empty.env diff --git a/.gitignore b/.gitignore index 4b891a2..d733a7f 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,3 @@ -hass/ - # ---> Python # Byte-compiled / optimized / DLL files __pycache__/ diff --git a/hass/.dockerignore b/hass/.dockerignore new file mode 100644 index 0000000..e1bffe5 --- /dev/null +++ b/hass/.dockerignore @@ -0,0 +1,2 @@ +.git/ +core/.git/ diff --git a/hass/.gitignore b/hass/.gitignore new file mode 100644 index 0000000..8157887 --- /dev/null +++ b/hass/.gitignore @@ -0,0 +1 @@ +core/ diff --git a/hass/.pipeline/empty.env b/hass/.pipeline/empty.env new file mode 100644 index 0000000..e69de29 -- 2.40.1 From f021469177fc1970cd2eeaccdcad009bed0cb5f9 Mon Sep 17 00:00:00 2001 From: Ben Kristinsson Date: Mon, 3 Apr 2023 01:03:03 +0200 Subject: [PATCH 3/4] airconnect disable listen on stdon, caused 100% cpu --- airconnect/docker/entrypoint.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/airconnect/docker/entrypoint.sh b/airconnect/docker/entrypoint.sh index 40a4255..11c06ca 100755 --- a/airconnect/docker/entrypoint.sh +++ b/airconnect/docker/entrypoint.sh @@ -38,7 +38,7 @@ fi if [ "$ARGS" = "" ]; then if [ "$PROG" = "airupnp" ]; then # set default args for airupnp if not set - ARGS="-x $AIRCONNECT_AIRUPNP_CONFIG" + ARGS="-Z -x $AIRCONNECT_AIRUPNP_CONFIG" elif [ "$PROG" = "aircast" ]; then # no default args for aircast -- 2.40.1 From 4a08dd197f8b2fd5fb7641182a5e2c8ec0c7d29f Mon Sep 17 00:00:00 2001 From: Ben Kristinsson Date: Mon, 3 Apr 2023 01:03:47 +0200 Subject: [PATCH 4/4] airconnect -Z in readme --- airconnect/README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/airconnect/README.md b/airconnect/README.md index 13061cf..7d6abaf 100644 --- a/airconnect/README.md +++ b/airconnect/README.md @@ -21,7 +21,7 @@ for `airupnp` (UPnP/Sonos): ```shell # pass cmdline args: docker run --name airconnect-airupnp -it --net=host \ - git.sudo.is/ben/airconnect airupnp -l 1000:2000 + git.sudo.is/ben/airconnect airupnp -Z -l 1000:2000 # if you want to mount an /etc/airupnp.xml config file instead: docker run --name airconnect-airupnp -it --net=host \ @@ -29,6 +29,10 @@ docker run --name airconnect-airupnp -it --net=host \ git.sudo.is/ben/airconnect airupnp ``` +here the `-Z` argument is importabt, it instructs +airconnect to not listen to input on stdin. otherwise +it will loop indefinitely and use 100% cpu. + for `aircast` (Chromecast): ```shell -- 2.40.1