This commit is contained in:
Alexandre
2023-09-09 19:49:39 +02:00
parent a46e58b8a3
commit 954460e73a
3 changed files with 6 additions and 4 deletions

View File

@@ -64,12 +64,13 @@ RUN \
if [ -d /etc/cont-init.d ]; then chmod -R 755 /etc/cont-init.d; fi && \ if [ -d /etc/cont-init.d ]; then chmod -R 755 /etc/cont-init.d; fi && \
if [ -d /etc/services.d ]; then chmod -R 755 /etc/services.d; fi && \ if [ -d /etc/services.d ]; then chmod -R 755 /etc/services.d; fi && \
#Correct shebang in entrypoint #Correct shebang in entrypoint
for shebang in "/command/with-contenv bashio" "/usr/bin/env bashio" "/usr/bin/bashio" "/bin/bash" "/bin/sh"; do if [ -f "${shebang%% *}" ]; then break; fi; done; sed -i "s|/command/with-contenv bashio|$shebang|g" /ha_entrypoint.sh for shebang in "/command/with-contenv bashio" "/usr/bin/env bashio" "/usr/bin/bashio" "/bin/bash" "/bin/sh"; do if [ -f "${shebang%% *}" ]; then break; fi; done; sed -i "s|/command/with-contenv bashio|$shebang|g" /ha_entrypoint.sh && \
echo "Shebang is $shebang"
# Entrypoint logic # Entrypoint logic
#WORKDIR / #WORKDIR /
ENTRYPOINT [ "/usr/bin/env" ] ENTRYPOINT [ "/ha_entrypoint.sh" ]
CMD [ "/ha_entrypoint.sh" ] CMD [ "/ha_entrypoint.sh" ]
# Set shell # Set shell
SHELL ["/bin/bash", "-o", "pipefail", "-c"] SHELL ["/bin/bash", "-o", "pipefail", "-c"]

View File

@@ -31,5 +31,5 @@
}, },
"slug": "test", "slug": "test",
"url": "https://github.com/alexbelgium/hassio-addons/tree/master/addons_updater", "url": "https://github.com/alexbelgium/hassio-addons/tree/master/addons_updater",
"version": "test3" "version": "test4"
} }

View File

@@ -1,5 +1,6 @@
#!/usr/bin/env bashio #!/bin/bash
# shellcheck shell=bash # shellcheck shell=bash
echo "nearly"
bashio::log.info "It's working" bashio::log.info "It's working"