From caf5fae8a849f740a603e0377be75df2043fae7f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernhard=20Gro=C3=9Fer?= Date: Mon, 21 Jun 2021 19:33:21 +0200 Subject: [PATCH 001/435] Added feature for subfolder hosting By setting the SUBFOLDER env var, you can host Homer in a subfolder behind a reverse proxy. --- README.md | 4 ++++ entrypoint.sh | 6 ++++++ 2 files changed, 10 insertions(+) diff --git a/README.md b/README.md index 5ea80fb..57185a7 100644 --- a/README.md +++ b/README.md @@ -83,6 +83,10 @@ docker run -d \ Default assets will be automatically installed in the `/www/assets` directory. Use `UID` and/or `GID` env var to change the assets owner (`docker run -e "UID=1000" -e "GID=1000" [...]`). +## Host in subfolder + +If you would like to host Homer in a subfolder, for e.g. behind a reverse proxy, supply the name of subfolder by using the `SUBFOLDER` env var. + ### Using docker-compose The `docker-compose.yml` file must be edited to match your needs. diff --git a/entrypoint.sh b/entrypoint.sh index f1a8c22..9da2615 100644 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -11,5 +11,11 @@ fi # Install default config if no one is available. yes n | cp -i /www/default-assets/config.yml.dist /www/assets/config.yml &> /dev/null +# Create symbolic link for hosting in subfolder. +if [[ -n "${SUBFOLDER}" ]]; then + ln -s /www "/www/$SUBFOLDER" + chown -h $USER:$GROUP "/www/$SUBFOLDER" +fi + chown -R $UID:$GID /www/assets exec su-exec $UID:$GID darkhttpd /www/ --no-listing --port "$PORT" From b6b31e440c7915e82fe8b9a4b93083ec9fb2e9fd Mon Sep 17 00:00:00 2001 From: Kirmy Date: Thu, 9 Dec 2021 13:09:09 +0100 Subject: [PATCH 002/435] Replaced darkhttpd with lighttpd --- Dockerfile | 7 ++++--- Dockerfile.arm32v7 | 7 ++++--- Dockerfile.arm64v8 | 7 ++++--- entrypoint.sh | 4 +++- lighttpd.conf | 20 ++++++++++++++++++++ 5 files changed, 35 insertions(+), 10 deletions(-) create mode 100644 lighttpd.conf diff --git a/Dockerfile b/Dockerfile index 0a43027..f24d7be 100644 --- a/Dockerfile +++ b/Dockerfile @@ -12,18 +12,19 @@ RUN yarn build # production stage FROM alpine:3.15 -ENV USER darkhttpd -ENV GROUP darkhttpd +ENV USER lighttpd +ENV GROUP lighttpd ENV GID 911 ENV UID 911 ENV PORT 8080 RUN addgroup -S ${GROUP} -g ${GID} && adduser -D -S -u ${UID} ${USER} ${GROUP} && \ - apk add -U --no-cache su-exec darkhttpd + apk add -U --no-cache lighttpd COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets COPY entrypoint.sh /entrypoint.sh +COPY lighttpd.conf /lighttpd.conf HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 diff --git a/Dockerfile.arm32v7 b/Dockerfile.arm32v7 index 95a2db1..2256d2a 100644 --- a/Dockerfile.arm32v7 +++ b/Dockerfile.arm32v7 @@ -21,19 +21,20 @@ FROM arm32v7/alpine:3.11 COPY --from=qemu qemu-arm-static /usr/bin/ -ENV USER darkhttpd -ENV GROUP darkhttpd +ENV USER lighttpd +ENV GROUP lighttpd ENV GID 911 ENV UID 911 ENV PORT 8080 RUN addgroup -S ${GROUP} -g ${GID} && adduser -D -S -u ${UID} ${USER} ${GROUP} && \ - apk add -U --no-cache darkhttpd su-exec && \ + apk add -U --no-cache lighttpd && \ rm /usr/bin/qemu-arm-static COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets COPY entrypoint.sh /entrypoint.sh +COPY lighttpd.conf /lighttpd.conf HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 diff --git a/Dockerfile.arm64v8 b/Dockerfile.arm64v8 index cd15e4a..7d772f0 100644 --- a/Dockerfile.arm64v8 +++ b/Dockerfile.arm64v8 @@ -21,19 +21,20 @@ FROM arm64v8/alpine:3.11 COPY --from=qemu qemu-aarch64-static /usr/bin/ -ENV USER darkhttpd -ENV GROUP darkhttpd +ENV USER lighttpd +ENV GROUP lighttpd ENV GID 911 ENV UID 911 ENV PORT 8080 RUN addgroup -S ${GROUP} -g ${GID} && adduser -D -S -u ${UID} ${USER} ${GROUP} && \ - apk add -U --no-cache darkhttpd su-exec && \ + apk add -U --no-cache lighttpd && \ rm /usr/bin/qemu-aarch64-static COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets COPY entrypoint.sh /entrypoint.sh +COPY lighttpd.conf /lighttpd.conf HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 diff --git a/entrypoint.sh b/entrypoint.sh index 9da2615..e10e17e 100644 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -18,4 +18,6 @@ if [[ -n "${SUBFOLDER}" ]]; then fi chown -R $UID:$GID /www/assets -exec su-exec $UID:$GID darkhttpd /www/ --no-listing --port "$PORT" + +echo "Starting webserver" +lighttpd -D -f /lighttpd.conf diff --git a/lighttpd.conf b/lighttpd.conf new file mode 100644 index 0000000..da72bf9 --- /dev/null +++ b/lighttpd.conf @@ -0,0 +1,20 @@ +# Minimal config by Kirmy34 + +include "/etc/lighttpd/mime-types.conf" + +server.port = 8080 + +server.username = "lighttpd" +server.groupname = "lighttpd" + +server.document-root = "/www" +server.pid-file = "/run/lighttpd.pid" + +server.indexfiles = ("index.php", "index.html", "index.htm", "default.htm") + +server.follow-symlink = "enable" + +static-file.exclude-extensions = (".php", ".pl", ".cgi", ".fcgi") + +url.access-deny = ("~", ".inc") + From cd75da69f9e57c3fe0f63c3ed6def0577d75a47c Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 20 Mar 2022 21:46:36 +0100 Subject: [PATCH 003/435] Alias subfolder hosting --- Dockerfile | 5 +++-- Dockerfile.arm32v7 | 5 +++-- Dockerfile.arm64v8 | 5 +++-- lighttpd.conf | 24 +++++++----------------- 4 files changed, 16 insertions(+), 23 deletions(-) diff --git a/Dockerfile b/Dockerfile index f24d7be..ffe50c4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -17,15 +17,16 @@ ENV GROUP lighttpd ENV GID 911 ENV UID 911 ENV PORT 8080 +ENV SUBFOLDER "/_" RUN addgroup -S ${GROUP} -g ${GID} && adduser -D -S -u ${UID} ${USER} ${GROUP} && \ apk add -U --no-cache lighttpd -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets COPY entrypoint.sh /entrypoint.sh COPY lighttpd.conf /lighttpd.conf +COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ +COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 diff --git a/Dockerfile.arm32v7 b/Dockerfile.arm32v7 index 2256d2a..01a2196 100644 --- a/Dockerfile.arm32v7 +++ b/Dockerfile.arm32v7 @@ -26,16 +26,17 @@ ENV GROUP lighttpd ENV GID 911 ENV UID 911 ENV PORT 8080 +ENV SUBFOLDER "/_" RUN addgroup -S ${GROUP} -g ${GID} && adduser -D -S -u ${UID} ${USER} ${GROUP} && \ apk add -U --no-cache lighttpd && \ rm /usr/bin/qemu-arm-static -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets COPY entrypoint.sh /entrypoint.sh COPY lighttpd.conf /lighttpd.conf +COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ +COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 diff --git a/Dockerfile.arm64v8 b/Dockerfile.arm64v8 index 7d772f0..f9e6675 100644 --- a/Dockerfile.arm64v8 +++ b/Dockerfile.arm64v8 @@ -26,16 +26,17 @@ ENV GROUP lighttpd ENV GID 911 ENV UID 911 ENV PORT 8080 +ENV SUBFOLDER "/_" RUN addgroup -S ${GROUP} -g ${GID} && adduser -D -S -u ${UID} ${USER} ${GROUP} && \ apk add -U --no-cache lighttpd && \ rm /usr/bin/qemu-aarch64-static -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets COPY entrypoint.sh /entrypoint.sh COPY lighttpd.conf /lighttpd.conf +COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ +COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 diff --git a/lighttpd.conf b/lighttpd.conf index da72bf9..04b0bed 100644 --- a/lighttpd.conf +++ b/lighttpd.conf @@ -1,20 +1,10 @@ -# Minimal config by Kirmy34 - include "/etc/lighttpd/mime-types.conf" -server.port = 8080 - -server.username = "lighttpd" -server.groupname = "lighttpd" - -server.document-root = "/www" -server.pid-file = "/run/lighttpd.pid" - -server.indexfiles = ("index.php", "index.html", "index.htm", "default.htm") - +server.port = env.PORT +server.modules = ( "mod_alias" ) +server.username = env.USER +server.groupname = env.GROUP +server.document-root = "/www" +alias.url = ( env.SUBFOLDER => "/www" ) +server.indexfiles = ("index.html") server.follow-symlink = "enable" - -static-file.exclude-extensions = (".php", ".pl", ".cgi", ".fcgi") - -url.access-deny = ("~", ".inc") - From 049f85221e945b90bf87d21afe4d306839d65740 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 10 Apr 2022 11:55:11 +0200 Subject: [PATCH 004/435] Simplify the container starting process to allow it to run with a unprivileged user --- Dockerfile | 20 ++++++++++++-------- Dockerfile.arm32v7 | 10 ++++++---- Dockerfile.arm64v8 | 10 ++++++---- README.md | 25 +++++++++---------------- docker-compose.yml | 7 +++---- entrypoint.sh | 27 +++++++++++---------------- lighttpd.conf | 4 ++-- src/assets/app.scss | 4 ++++ 8 files changed, 53 insertions(+), 54 deletions(-) diff --git a/Dockerfile b/Dockerfile index ffe50c4..0e9d51a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -12,24 +12,28 @@ RUN yarn build # production stage FROM alpine:3.15 -ENV USER lighttpd -ENV GROUP lighttpd -ENV GID 911 -ENV UID 911 +ENV GID 1000 +ENV UID 1000 ENV PORT 8080 ENV SUBFOLDER "/_" +ENV INIT_ASSETS 1 -RUN addgroup -S ${GROUP} -g ${GID} && adduser -D -S -u ${UID} ${USER} ${GROUP} && \ +RUN addgroup -S lighttpd -g ${GID} && adduser -D -S -u ${UID} lighttpd lighttpd && \ apk add -U --no-cache lighttpd -COPY entrypoint.sh /entrypoint.sh -COPY lighttpd.conf /lighttpd.conf +WORKDIR /www -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ +COPY lighttpd.conf /lighttpd.conf +COPY entrypoint.sh /entrypoint.sh +COPY --from=build-stage --chown=${UID}:${GID} /app/dist /www/ COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets + +USER ${UID}:${GID} + HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 EXPOSE ${PORT} VOLUME /www/assets + ENTRYPOINT ["/bin/sh", "/entrypoint.sh"] diff --git a/Dockerfile.arm32v7 b/Dockerfile.arm32v7 index 01a2196..7e1d92b 100644 --- a/Dockerfile.arm32v7 +++ b/Dockerfile.arm32v7 @@ -32,14 +32,16 @@ RUN addgroup -S ${GROUP} -g ${GID} && adduser -D -S -u ${UID} ${USER} ${GROUP} & apk add -U --no-cache lighttpd && \ rm /usr/bin/qemu-arm-static -COPY entrypoint.sh /entrypoint.sh -COPY lighttpd.conf /lighttpd.conf +WORKDIR /www +COPY lighttpd.conf /lighttpd.conf COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets + +USER ${USER} HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 EXPOSE ${PORT} VOLUME /www/assets -ENTRYPOINT ["/bin/sh", "/entrypoint.sh"] + +CMD ["lighttpd", "-D", "-f", "/lighttpd.conf"] diff --git a/Dockerfile.arm64v8 b/Dockerfile.arm64v8 index f9e6675..573a2e4 100644 --- a/Dockerfile.arm64v8 +++ b/Dockerfile.arm64v8 @@ -32,14 +32,16 @@ RUN addgroup -S ${GROUP} -g ${GID} && adduser -D -S -u ${UID} ${USER} ${GROUP} & apk add -U --no-cache lighttpd && \ rm /usr/bin/qemu-aarch64-static -COPY entrypoint.sh /entrypoint.sh -COPY lighttpd.conf /lighttpd.conf +WORKDIR /www +COPY lighttpd.conf /lighttpd.conf COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets + +USER ${USER} HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 EXPOSE ${PORT} VOLUME /www/assets -ENTRYPOINT ["/bin/sh", "/entrypoint.sh"] + +CMD ["lighttpd", "-D", "-f", "/lighttpd.conf"] diff --git a/README.md b/README.md index 57185a7..6ac71e6 100644 --- a/README.md +++ b/README.md @@ -71,8 +71,6 @@ See [documentation](docs/configuration.md) for information about the configurati ### Using docker -To launch container: - ```sh docker run -d \ -p 8080:8080 \ @@ -81,16 +79,19 @@ docker run -d \ b4bz/homer:latest ``` -Default assets will be automatically installed in the `/www/assets` directory. Use `UID` and/or `GID` env var to change the assets owner (`docker run -e "UID=1000" -e "GID=1000" [...]`). +Environment variables: -## Host in subfolder +* **`INIT_ASSETS`** (default: `1`) +Install exemple configuration file & assets (favicons, ...) to help you get started. + +* **`SUBFOLDER`** (default: `null`) +If you would like to host Homer in a subfolder, (ex: *http://my-domain/**homer***), set this to the subfolder path (ex `/homer`). -If you would like to host Homer in a subfolder, for e.g. behind a reverse proxy, supply the name of subfolder by using the `SUBFOLDER` env var. ### Using docker-compose The `docker-compose.yml` file must be edited to match your needs. -Set the port and volume (equivalent to `-p` and `-v` arguments): +You probably want to set the port mapping and volume binding (equivalent to `-p` and `-v` arguments): ```yaml volumes: @@ -99,21 +100,13 @@ ports: - 8080:8080 ``` -To launch container: +Then launch the container: ```sh -cd /path/to/docker-compose.yml +cd /path/to/docker-compose.yml/ docker-compose up -d ``` -Default assets will be automatically installed in the `/www/assets` directory. Use `UID` and/or `GID` env var to change the assets owner, also in `docker-compose.yml`: - -```yaml -environment: - - UID=1000 - - GID=1000 -``` - ### Using the release tarball (prebuilt, ready to use) Download and extract the latest release (`homer.zip`) from the [release page](https://github.com/bastienwirtz/homer/releases), rename the `assets/config.yml.dist` file to `assets/config.yml`, and put it behind a web server. diff --git a/docker-compose.yml b/docker-compose.yml index 884703c..231e72a 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -10,7 +10,6 @@ services: - /your/local/assets/:/www/assets ports: - 8080:8080 - #environment: - # - UID=1000 - # - GID=1000 - restart: unless-stopped + user: 1000:1000 # default + environment: + - INIT_ASSETS=1 # default diff --git a/entrypoint.sh b/entrypoint.sh index e10e17e..eba1cb2 100644 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -1,23 +1,18 @@ #!/bin/sh -# Ensure default assets are present. -while true; do echo n; done | cp -Ri /www/default-assets/* /www/assets/ &> /dev/null +PERMISSION_ERROR="Check assets directory permissions & docker user or skip default assets install by setting the INIT_ASSETS env var to 0" -# Ensure compatibility with previous version (config.yml was in the root directory) -if [ -f "/www/config.yml" ]; then - yes n | cp -i /www/config.yml /www/assets/ &> /dev/null +# Default assets & exemple configuration installation if possible. +if [[ "${INIT_ASSETS}" == "1" ]] && [[ ! -f "/www/config.yml" ]]; then + echo "No configuration found, installing default config & assets" + if [[ ! -w "/www/assets/" ]]; then echo "Assets directory not writable. $PERMISSION_ERROR" && exit 1; fi + + while true; do echo n; done | cp -Ri /www/default-assets/* /www/assets/ &> /dev/null + if [[ $? -ne 0 ]]; then echo "Fail to copy default assets. $PERMISSION_ERROR" && exit 1; fi + + yes n | cp -i /www/default-assets/config.yml.dist /www/assets/config.yml &> /dev/null + if [[ $? -ne 0 ]]; then echo "Fail to copy default config file. $PERMISSION_ERROR" && exit 1; fi fi -# Install default config if no one is available. -yes n | cp -i /www/default-assets/config.yml.dist /www/assets/config.yml &> /dev/null - -# Create symbolic link for hosting in subfolder. -if [[ -n "${SUBFOLDER}" ]]; then - ln -s /www "/www/$SUBFOLDER" - chown -h $USER:$GROUP "/www/$SUBFOLDER" -fi - -chown -R $UID:$GID /www/assets - echo "Starting webserver" lighttpd -D -f /lighttpd.conf diff --git a/lighttpd.conf b/lighttpd.conf index 04b0bed..32e14da 100644 --- a/lighttpd.conf +++ b/lighttpd.conf @@ -2,8 +2,8 @@ include "/etc/lighttpd/mime-types.conf" server.port = env.PORT server.modules = ( "mod_alias" ) -server.username = env.USER -server.groupname = env.GROUP +server.username = "lighttpd" +server.groupname = "lighttpd" server.document-root = "/www" alias.url = ( env.SUBFOLDER => "/www" ) server.indexfiles = ("index.html") diff --git a/src/assets/app.scss b/src/assets/app.scss index aa8b077..ae2cb6b 100644 --- a/src/assets/app.scss +++ b/src/assets/app.scss @@ -104,6 +104,10 @@ body { .dashboard-title { padding: 6px 0 0 80px; + + &.no-logo { + padding-left: 0; + } } .first-line { From 4f56c2c11baad8f98c338989fb0cd8e5af78d0c8 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 10 Apr 2022 11:56:44 +0200 Subject: [PATCH 005/435] Handle 404 error on config file. --- src/App.vue | 18 ++++++++++++++++-- src/components/GetStarted.vue | 2 +- src/components/services/Emby.vue | 2 +- 3 files changed, 18 insertions(+), 4 deletions(-) diff --git a/src/App.vue b/src/App.vue index 81f92f7..515177e 100644 --- a/src/App.vue +++ b/src/App.vue @@ -18,7 +18,10 @@ -
+
{{ config.subtitle }}

{{ config.title }}

@@ -61,7 +64,7 @@ @network-status-update="offline = $event" /> - +
@@ -168,6 +171,7 @@ export default { data: function () { return { loaded: false, + configNotFound: false, config: null, services: null, offline: false, @@ -177,6 +181,11 @@ export default { showMenu: false, }; }, + computed: { + configurationNeeded: function () { + return (this.loaded && !this.services) || this.configNotFound; + }, + }, created: async function () { this.buildDashboard(); window.onhashchange = this.buildDashboard; @@ -228,6 +237,11 @@ export default { return; } + if (response.status == 404) { + this.configNotFound = true; + return {}; + } + if (!response.ok) { throw Error(`${response.statusText}: ${response.body}`); } diff --git a/src/components/GetStarted.vue b/src/components/GetStarted.vue index dcabc02..c256a0f 100644 --- a/src/components/GetStarted.vue +++ b/src/components/GetStarted.vue @@ -6,7 +6,7 @@

Get started diff --git a/src/components/services/Emby.vue b/src/components/services/Emby.vue index 25a2612..d2411f0 100644 --- a/src/components/services/Emby.vue +++ b/src/components/services/Emby.vue @@ -62,7 +62,7 @@ export default { this.fetch("/System/info/public") .then((response) => { if (response.Id) this.status = "running"; - else throw new Error(); + else throw new Error(); }) .catch((e) => { console.log(e); From cab7bfd15e55b1cde48c9cd4f84032e1b9cc8ec9 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sat, 30 Apr 2022 15:58:04 +0200 Subject: [PATCH 006/435] Apply lastest update to arm dockerfile --- Dockerfile | 2 +- Dockerfile.arm32v7 | 16 +++++++++------- Dockerfile.arm64v8 | 16 +++++++++------- 3 files changed, 19 insertions(+), 15 deletions(-) diff --git a/Dockerfile b/Dockerfile index 0e9d51a..4d0c4e8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -26,7 +26,7 @@ WORKDIR /www COPY lighttpd.conf /lighttpd.conf COPY entrypoint.sh /entrypoint.sh COPY --from=build-stage --chown=${UID}:${GID} /app/dist /www/ -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist/assets /www/default-assets +COPY --from=build-stage --chown=${UID}:${GID} /app/dist/assets /www/default-assets USER ${UID}:${GID} diff --git a/Dockerfile.arm32v7 b/Dockerfile.arm32v7 index 7e1d92b..59a2639 100644 --- a/Dockerfile.arm32v7 +++ b/Dockerfile.arm32v7 @@ -21,23 +21,25 @@ FROM arm32v7/alpine:3.11 COPY --from=qemu qemu-arm-static /usr/bin/ -ENV USER lighttpd -ENV GROUP lighttpd -ENV GID 911 -ENV UID 911 +ENV GID 1000 +ENV UID 1000 ENV PORT 8080 ENV SUBFOLDER "/_" +ENV INIT_ASSETS 1 -RUN addgroup -S ${GROUP} -g ${GID} && adduser -D -S -u ${UID} ${USER} ${GROUP} && \ +RUN addgroup -S lighttpd -g ${GID} && adduser -D -S -u ${UID} lighttpd lighttpd && \ apk add -U --no-cache lighttpd && \ rm /usr/bin/qemu-arm-static WORKDIR /www COPY lighttpd.conf /lighttpd.conf -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ +COPY entrypoint.sh /entrypoint.sh +COPY --from=build-stage --chown=${UID}:${GID} /app/dist /www/ +COPY --from=build-stage --chown=${UID}:${GID} /app/dist/assets /www/default-assets + +USER ${UID}:${GID} -USER ${USER} HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 diff --git a/Dockerfile.arm64v8 b/Dockerfile.arm64v8 index 573a2e4..d948db7 100644 --- a/Dockerfile.arm64v8 +++ b/Dockerfile.arm64v8 @@ -21,23 +21,25 @@ FROM arm64v8/alpine:3.11 COPY --from=qemu qemu-aarch64-static /usr/bin/ -ENV USER lighttpd -ENV GROUP lighttpd -ENV GID 911 -ENV UID 911 +ENV GID 1000 +ENV UID 1000 ENV PORT 8080 ENV SUBFOLDER "/_" +ENV INIT_ASSETS 1 -RUN addgroup -S ${GROUP} -g ${GID} && adduser -D -S -u ${UID} ${USER} ${GROUP} && \ +RUN addgroup -S lighttpd -g ${GID} && adduser -D -S -u ${UID} lighttpd lighttpd && \ apk add -U --no-cache lighttpd && \ rm /usr/bin/qemu-aarch64-static WORKDIR /www COPY lighttpd.conf /lighttpd.conf -COPY --from=build-stage --chown=${USER}:${GROUP} /app/dist /www/ +COPY entrypoint.sh /entrypoint.sh +COPY --from=build-stage --chown=${UID}:${GID} /app/dist /www/ +COPY --from=build-stage --chown=${UID}:${GID} /app/dist/assets /www/default-assets + +USER ${UID}:${GID} -USER ${USER} HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 From 766efb1a193aab39c780af1f013ab48af1830ba8 Mon Sep 17 00:00:00 2001 From: Benjamin Rumble Date: Tue, 3 May 2022 13:00:49 -0400 Subject: [PATCH 007/435] Update README.md exemple -> example --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 6ac71e6..5a08483 100644 --- a/README.md +++ b/README.md @@ -82,7 +82,7 @@ docker run -d \ Environment variables: * **`INIT_ASSETS`** (default: `1`) -Install exemple configuration file & assets (favicons, ...) to help you get started. +Install example configuration file & assets (favicons, ...) to help you get started. * **`SUBFOLDER`** (default: `null`) If you would like to host Homer in a subfolder, (ex: *http://my-domain/**homer***), set this to the subfolder path (ex `/homer`). From bf2fcc6641643018bd5224ec2f8308173d54cfa4 Mon Sep 17 00:00:00 2001 From: Pierre <397503+bemble@users.noreply.github.com> Date: Mon, 9 May 2022 23:47:05 +0200 Subject: [PATCH 008/435] feat(pwa): enhance connectivity checks Also add support to auth proxy such as Authelia --- src/components/ConnectivityChecker.vue | 25 +++++++++++++++++++++++++ vue.config.js | 3 +++ 2 files changed, 28 insertions(+) diff --git a/src/components/ConnectivityChecker.vue b/src/components/ConnectivityChecker.vue index 02cbd7f..a717bcf 100644 --- a/src/components/ConnectivityChecker.vue +++ b/src/components/ConnectivityChecker.vue @@ -29,15 +29,40 @@ export default { }, false ); + window.addEventListener( + "online", + function () { + that.checkOffline(); + }, + false + ); + window.addEventListener( + "offline", + function () { + this.offline = true; + }, + false + ); }, methods: { checkOffline: function () { + if (!navigator.onLine) { + this.offline = true; + return; + } + + // extra check to make sure we're not offline let that = this; return fetch(window.location.href + "?alive", { method: "HEAD", cache: "no-store", + redirect: "manual" }) .then(function (response) { + // opaqueredirect means request has been redirected, to auth provider probably + if (response.type === "opaqueredirect" && !response.ok) { + window.location.reload(true); + } that.offline = !response.ok; }) .catch(function () { diff --git a/vue.config.js b/vue.config.js index 410acc8..1645c2f 100644 --- a/vue.config.js +++ b/vue.config.js @@ -26,4 +26,7 @@ module.exports = { msTileImage: "assets/icons/icon-any.png", }, }, + devServer: { + disableHostCheck: true + }, }; From 98b460d6fe0e09cbdbf37f882f5e5bf7daa48e73 Mon Sep 17 00:00:00 2001 From: Pierre <397503+bemble@users.noreply.github.com> Date: Tue, 10 May 2022 09:46:42 +0200 Subject: [PATCH 009/435] fix(auth): add timestamp in URL to prevent infinite redirection loop --- src/components/ConnectivityChecker.vue | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/components/ConnectivityChecker.vue b/src/components/ConnectivityChecker.vue index a717bcf..1c677d2 100644 --- a/src/components/ConnectivityChecker.vue +++ b/src/components/ConnectivityChecker.vue @@ -17,6 +17,9 @@ export default { }; }, created: function () { + if (/t=\d+/.test(window.location.href)) { + window.history.replaceState({}, document.title, window.location.pathname); + } let that = this; this.checkOffline(); @@ -61,7 +64,7 @@ export default { .then(function (response) { // opaqueredirect means request has been redirected, to auth provider probably if (response.type === "opaqueredirect" && !response.ok) { - window.location.reload(true); + window.location.href = window.location.href + "?t="+(new Date().valueOf()); } that.offline = !response.ok; }) From 9506ed53c8ae78488aadff030366186af3cbd1ec Mon Sep 17 00:00:00 2001 From: James Coleman Date: Thu, 12 May 2022 17:30:24 -0500 Subject: [PATCH 010/435] Add support for search keywords to solve issue #372 --- docs/configuration.md | 1 + public/assets/config.yml.dist | 1 + src/App.vue | 3 ++- 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/configuration.md b/docs/configuration.md index 84a7ea7..6eb54c0 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -127,6 +127,7 @@ services: # icon: "fab fa-jenkins" subtitle: "Bookmark example" tag: "app" + keywords: "self hosted reddit" url: "https://www.reddit.com/r/selfhosted/" target: "_blank" # optional html tag target attribute - name: "Another one" diff --git a/public/assets/config.yml.dist b/public/assets/config.yml.dist index 03a8682..bbfd0af 100644 --- a/public/assets/config.yml.dist +++ b/public/assets/config.yml.dist @@ -75,6 +75,7 @@ services: logo: "assets/tools/sample.png" subtitle: "Bookmark example" tag: "app" + keywords: "self hosted reddit" url: "https://www.reddit.com/r/selfhosted/" target: "_blank" # optional html a tag target attribute - name: "Another one" diff --git a/src/App.vue b/src/App.vue index 515177e..c58fca1 100644 --- a/src/App.vue +++ b/src/App.vue @@ -264,7 +264,8 @@ export default { return ( item.name.toLowerCase().includes(this.filter) || (item.subtitle && item.subtitle.toLowerCase().includes(this.filter)) || - (item.tag && item.tag.toLowerCase().includes(this.filter)) + (item.tag && item.tag.toLowerCase().includes(this.filter)) || + (item.keywords && item.keywords.toLowerCase().includes(this.filter)) ); }, navigateToFirstService: function (target) { From 4353f5e03658778b526dca6b7dd3f5bd6e31e121 Mon Sep 17 00:00:00 2001 From: Pierre <397503+bemble@users.noreply.github.com> Date: Mon, 16 May 2022 14:52:46 +0200 Subject: [PATCH 011/435] feat(auth): handle unauthorized request in connectivity Reload page without cache if 401 and 403 status in response --- src/components/ConnectivityChecker.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/ConnectivityChecker.vue b/src/components/ConnectivityChecker.vue index 1c677d2..0d7e79f 100644 --- a/src/components/ConnectivityChecker.vue +++ b/src/components/ConnectivityChecker.vue @@ -63,7 +63,7 @@ export default { }) .then(function (response) { // opaqueredirect means request has been redirected, to auth provider probably - if (response.type === "opaqueredirect" && !response.ok) { + if ((response.type === "opaqueredirect" && !response.ok) || [401, 403].indexOf(response.status) != -1) { window.location.href = window.location.href + "?t="+(new Date().valueOf()); } that.offline = !response.ok; From bf6b543bfbff755973ecede8d8bedf50ed2a3d3b Mon Sep 17 00:00:00 2001 From: Eric Perko Date: Sat, 21 May 2022 22:22:17 -0400 Subject: [PATCH 012/435] Emby service also supports Jellyfin --- docs/customservices.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/customservices.md b/docs/customservices.md index 00d3288..efe8ca4 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -16,7 +16,7 @@ within Homer: + [Prometheus](#prometheus) + [AdGuard Home](#adguard-home) + [Portainer](#portainer) -+ [Emby](#emby) ++ [Emby / Jellyfin](#emby--jellyfin) + [Uptime Kuma](#uptime-kuma) + [Tautulli](#tautulli) @@ -169,7 +169,7 @@ See https://docs.portainer.io/v/ce-2.11/user/account-settings#access-tokens # - "local" ``` -## Emby +## Emby / Jellyfin You need to set the type to Emby, provide an api key and choose which stats to show if the subtitle is disabled. From 7f4130fd047c34159911b72057b1de521541631b Mon Sep 17 00:00:00 2001 From: "Mr. Gecko" Date: Mon, 23 May 2022 16:58:53 -0500 Subject: [PATCH 013/435] Update docs/configuration.md Add comment to describe keywords Co-authored-by: Bastien Wirtz --- docs/configuration.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/configuration.md b/docs/configuration.md index 6eb54c0..bb41948 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -127,7 +127,7 @@ services: # icon: "fab fa-jenkins" subtitle: "Bookmark example" tag: "app" - keywords: "self hosted reddit" + keywords: "self hosted reddit" # optional keyword used for searching purpose url: "https://www.reddit.com/r/selfhosted/" target: "_blank" # optional html tag target attribute - name: "Another one" From 95d73348e5dd8fd0fbb1b6747c58b346ecf772ad Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 29 May 2022 09:46:05 +0200 Subject: [PATCH 014/435] Updates --- Dockerfile | 2 +- Dockerfile.arm32v7 | 2 +- Dockerfile.arm64v8 | 2 +- package.json | 12 +-- src/components/services/Tautulli.vue | 6 +- src/components/services/UptimeKuma.vue | 4 +- yarn.lock | 142 ++++++++++++------------- 7 files changed, 87 insertions(+), 83 deletions(-) diff --git a/Dockerfile b/Dockerfile index 4d0c4e8..112db17 100644 --- a/Dockerfile +++ b/Dockerfile @@ -10,7 +10,7 @@ COPY . . RUN yarn build # production stage -FROM alpine:3.15 +FROM alpine:3.16 ENV GID 1000 ENV UID 1000 diff --git a/Dockerfile.arm32v7 b/Dockerfile.arm32v7 index 59a2639..270d7b5 100644 --- a/Dockerfile.arm32v7 +++ b/Dockerfile.arm32v7 @@ -17,7 +17,7 @@ ARG QEMU_VERSION="v4.2.0-7" RUN wget https://github.com/multiarch/qemu-user-static/releases/download/${QEMU_VERSION}/qemu-arm-static && chmod +x qemu-arm-static # production stage -FROM arm32v7/alpine:3.11 +FROM arm32v7/alpine:3.16 COPY --from=qemu qemu-arm-static /usr/bin/ diff --git a/Dockerfile.arm64v8 b/Dockerfile.arm64v8 index d948db7..f940bde 100644 --- a/Dockerfile.arm64v8 +++ b/Dockerfile.arm64v8 @@ -17,7 +17,7 @@ ARG QEMU_VERSION="v4.2.0-7" RUN wget https://github.com/multiarch/qemu-user-static/releases/download/${QEMU_VERSION}/qemu-aarch64-static && chmod +x qemu-aarch64-static # production stage -FROM arm64v8/alpine:3.11 +FROM arm64v8/alpine:3.16 COPY --from=qemu qemu-aarch64-static /usr/bin/ diff --git a/package.json b/package.json index 14ba6b4..a6d5fbf 100644 --- a/package.json +++ b/package.json @@ -8,18 +8,18 @@ }, "dependencies": { "@fortawesome/fontawesome-free": "^6.1.1", - "bulma": "^0.9.3", - "core-js": "^3.21.1", + "bulma": "^0.9.4", + "core-js": "^3.22.7", "js-yaml": "^4.1.0", "lodash.merge": "^4.6.2", "register-service-worker": "^1.7.2", "vue": "^2.6.14" }, "devDependencies": { - "@vue/cli-plugin-babel": "~4.5.15", - "@vue/cli-plugin-eslint": "~4.5.15", - "@vue/cli-plugin-pwa": "~4.5.15", - "@vue/cli-service": "~4.5.15", + "@vue/cli-plugin-babel": "~4.5.17", + "@vue/cli-plugin-eslint": "~4.5.17", + "@vue/cli-plugin-pwa": "~4.5.17", + "@vue/cli-service": "~4.5.17", "@vue/eslint-config-prettier": "^6.0.0", "babel-eslint": "^10.1.0", "eslint": "^6.7.2", diff --git a/src/components/services/Tautulli.vue b/src/components/services/Tautulli.vue index 2e8f8f5..0f27ff1 100644 --- a/src/components/services/Tautulli.vue +++ b/src/components/services/Tautulli.vue @@ -50,14 +50,16 @@ export default { methods: { fetchStatus: async function () { try { - const response = await this.fetch(`/api/v2?apikey=${this.item.apikey}&cmd=get_activity`); + const response = await this.fetch( + `/api/v2?apikey=${this.item.apikey}&cmd=get_activity` + ); this.error = false; this.stats = response.response.data; } catch (e) { this.error = true; console.error(e); } - } + }, }, }; diff --git a/src/components/services/UptimeKuma.vue b/src/components/services/UptimeKuma.vue index 5dd75f3..3be53b8 100644 --- a/src/components/services/UptimeKuma.vue +++ b/src/components/services/UptimeKuma.vue @@ -108,7 +108,9 @@ export default { .catch((e) => console.error(e)) .then((resp) => (this.incident = resp)); - this.fetch(`/api/status-page/heartbeat/${this.dashboard}?cachebust=${Date.now()}`) + this.fetch( + `/api/status-page/heartbeat/${this.dashboard}?cachebust=${Date.now()}` + ) .catch((e) => console.error(e)) .then((resp) => (this.heartbeat = resp)); }, diff --git a/yarn.lock b/yarn.lock index fdc3260..e21871d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,6 +2,15 @@ # yarn lockfile v1 +"@achrinza/node-ipc@9.2.2": + version "9.2.2" + resolved "https://registry.yarnpkg.com/@achrinza/node-ipc/-/node-ipc-9.2.2.tgz#ae1b5d3d6a9362034eea60c8d946b93893c2e4ec" + integrity sha512-b90U39dx0cU6emsOvy5hxU4ApNXnE3+Tuo8XQZfiKTGelDwpMwBVgBP7QX6dGTcJgu/miyJuNJ/2naFBliNWEw== + dependencies: + "@node-ipc/js-queue" "2.0.3" + event-pubsub "4.3.0" + js-message "1.0.7" + "@babel/code-frame@^7.0.0", "@babel/code-frame@^7.14.5": version "7.14.5" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.14.5.tgz#23b08d740e83f49c5e59945fbf1b43e80bbf4edb" @@ -957,6 +966,13 @@ call-me-maybe "^1.0.1" glob-to-regexp "^0.3.0" +"@node-ipc/js-queue@2.0.3": + version "2.0.3" + resolved "https://registry.yarnpkg.com/@node-ipc/js-queue/-/js-queue-2.0.3.tgz#ac7fe33d766fa53e233ef8fedaf3443a01c5a4cd" + integrity sha512-fL1wpr8hhD5gT2dA1qifeVaoDFlQR5es8tFuKqjHX+kdOtdNHnxkVZbtIrR2rxnMFvehkjaZRNV2H/gPXlb0hw== + dependencies: + easy-stack "1.0.1" + "@nodelib/fs.stat@^1.1.2": version "1.1.3" resolved "https://registry.yarnpkg.com/@nodelib/fs.stat/-/fs.stat-1.1.3.tgz#2b5a3ab3f918cca48a8c754c08168e3f03eba61b" @@ -1173,10 +1189,10 @@ lodash.kebabcase "^4.1.1" svg-tags "^1.0.0" -"@vue/babel-preset-app@^4.5.15": - version "4.5.15" - resolved "https://registry.yarnpkg.com/@vue/babel-preset-app/-/babel-preset-app-4.5.15.tgz#f6bc08f8f674e98a260004234cde18b966d72eb0" - integrity sha512-J+YttzvwRfV1BPczf8r3qCevznYk+jh531agVF+5EYlHF4Sgh/cGXTz9qkkiux3LQgvhEGXgmCteg1n38WuuKg== +"@vue/babel-preset-app@^4.5.17": + version "4.5.17" + resolved "https://registry.yarnpkg.com/@vue/babel-preset-app/-/babel-preset-app-4.5.17.tgz#09c64eedfe868bfa3121fc12a59138518f830bde" + integrity sha512-iFv9J3F5VKUPcbx+TqW5qhGmAVyXQxPRpKpPOuTLFIVTzg+iwJnrqVbL4kJU5ECGDxPESW2oCVgxv9bTlDPu7w== dependencies: "@babel/core" "^7.11.0" "@babel/helper-compilation-targets" "^7.9.6" @@ -1258,61 +1274,61 @@ "@vue/babel-plugin-transform-vue-jsx" "^1.2.1" camelcase "^5.0.0" -"@vue/cli-overlay@^4.5.15": - version "4.5.15" - resolved "https://registry.yarnpkg.com/@vue/cli-overlay/-/cli-overlay-4.5.15.tgz#0700fd6bad39336d4189ba3ff7d25e638e818c9c" - integrity sha512-0zI0kANAVmjFO2LWGUIzdGPMeE3+9k+KeRDXsUqB30YfRF7abjfiiRPq5BU9pOzlJbVdpRkisschBrvdJqDuDg== +"@vue/cli-overlay@^4.5.17": + version "4.5.17" + resolved "https://registry.yarnpkg.com/@vue/cli-overlay/-/cli-overlay-4.5.17.tgz#4e0e24b7c3b71ff86de86f532821fd3abb48d10c" + integrity sha512-QKKp66VbMg+X8Qh0wgXSwgxLfxY7EIkZkV6bZ6nFqBx8xtaJQVDbTL+4zcUPPA6nygbIcQ6gvTinNEqIqX6FUQ== -"@vue/cli-plugin-babel@~4.5.15": - version "4.5.15" - resolved "https://registry.yarnpkg.com/@vue/cli-plugin-babel/-/cli-plugin-babel-4.5.15.tgz#ae4fb2ed54255fe3d84df381dab68509641179ed" - integrity sha512-hBLrwYfFkHldEe34op/YNgPhpOWI5n5DB2Qt9I/1Epeif4M4iFaayrgjvOR9AVM6WbD3Yx7WCFszYpWrQZpBzQ== +"@vue/cli-plugin-babel@~4.5.17": + version "4.5.17" + resolved "https://registry.yarnpkg.com/@vue/cli-plugin-babel/-/cli-plugin-babel-4.5.17.tgz#8c468e32ef6546f843201770a294bf599689e004" + integrity sha512-6kZuc3PdoUvGAnndUq6+GqjIXn3bqdTR8lOcAb1BH2b4N7IKGlmzcipALGS23HLVMAvDgNuUS7vf0unin9j2cg== dependencies: "@babel/core" "^7.11.0" - "@vue/babel-preset-app" "^4.5.15" - "@vue/cli-shared-utils" "^4.5.15" + "@vue/babel-preset-app" "^4.5.17" + "@vue/cli-shared-utils" "^4.5.17" babel-loader "^8.1.0" cache-loader "^4.1.0" thread-loader "^2.1.3" webpack "^4.0.0" -"@vue/cli-plugin-eslint@~4.5.15": - version "4.5.15" - resolved "https://registry.yarnpkg.com/@vue/cli-plugin-eslint/-/cli-plugin-eslint-4.5.15.tgz#5781824a941f34c26336a67b1f6584a06c6a24ff" - integrity sha512-/2Fl6wY/5bz3HD035oSnFRMsKNxDxU396KqBdpCQdwdvqk4mm6JAbXqihpcBRTNPeTO6w+LwGe6FE56PVbJdbg== +"@vue/cli-plugin-eslint@~4.5.17": + version "4.5.17" + resolved "https://registry.yarnpkg.com/@vue/cli-plugin-eslint/-/cli-plugin-eslint-4.5.17.tgz#7667bf87bdfdb39faeb3baed58657622354a17bc" + integrity sha512-bVNDP+SuWcuJrBMc+JLaKvlxx25XKIlZBa+zzFnxhHZlwPZ7CeBD3e2wnsygJyPoKgDZcZwDgmEz1BZzMEjsNw== dependencies: - "@vue/cli-shared-utils" "^4.5.15" + "@vue/cli-shared-utils" "^4.5.17" eslint-loader "^2.2.1" globby "^9.2.0" inquirer "^7.1.0" webpack "^4.0.0" yorkie "^2.0.0" -"@vue/cli-plugin-pwa@~4.5.15": - version "4.5.15" - resolved "https://registry.yarnpkg.com/@vue/cli-plugin-pwa/-/cli-plugin-pwa-4.5.15.tgz#eb800c418d96b496deec9d063a1798fe6e9c2db8" - integrity sha512-yQzsspaIkjeQyN6btF8ATgbJFU023q1HC8uUpmiBa4QE9EyBlR8fSrKFhcJ0EmT6KnU7PMwlnOJ/OqjguFnufA== +"@vue/cli-plugin-pwa@~4.5.17": + version "4.5.17" + resolved "https://registry.yarnpkg.com/@vue/cli-plugin-pwa/-/cli-plugin-pwa-4.5.17.tgz#73b2f9dd1203de46761a9843e972966e2717fe87" + integrity sha512-IaODWmj5eQjv97ne0CTOgPZA8QmVS7zYX64C+SivWPw0uevJAhNUdDHgyrUODP7fEfyufKliStLMQJTowohGNQ== dependencies: - "@vue/cli-shared-utils" "^4.5.15" + "@vue/cli-shared-utils" "^4.5.17" webpack "^4.0.0" workbox-webpack-plugin "^4.3.1" -"@vue/cli-plugin-router@^4.5.15": - version "4.5.15" - resolved "https://registry.yarnpkg.com/@vue/cli-plugin-router/-/cli-plugin-router-4.5.15.tgz#1e75c8c89df42c694f143b9f1028de3cf5d61e1e" - integrity sha512-q7Y6kP9b3k55Ca2j59xJ7XPA6x+iSRB+N4ac0ZbcL1TbInVQ4j5wCzyE+uqid40hLy4fUdlpl4X9fHJEwuVxPA== +"@vue/cli-plugin-router@^4.5.17": + version "4.5.17" + resolved "https://registry.yarnpkg.com/@vue/cli-plugin-router/-/cli-plugin-router-4.5.17.tgz#9de189a7a8740817cde2a4e57aade14552ff68c3" + integrity sha512-9r9CSwqv2+39XHQPDZJ0uaTtTP7oe0Gx17m7kBhHG3FA7R7AOSk2aVzhHZmDRhzlOxjx9kQSvrOSMfUG0kV4dQ== dependencies: - "@vue/cli-shared-utils" "^4.5.15" + "@vue/cli-shared-utils" "^4.5.17" -"@vue/cli-plugin-vuex@^4.5.15": - version "4.5.15" - resolved "https://registry.yarnpkg.com/@vue/cli-plugin-vuex/-/cli-plugin-vuex-4.5.15.tgz#466c1f02777d02fef53a9bb49a36cc3a3bcfec4e" - integrity sha512-fqap+4HN+w+InDxlA3hZTOGE0tzBTgXhKLoDydhywqgmhQ1D9JA6Feh94ze6tG8DsWX58/ujYUqA8jAz17FJtg== +"@vue/cli-plugin-vuex@^4.5.17": + version "4.5.17" + resolved "https://registry.yarnpkg.com/@vue/cli-plugin-vuex/-/cli-plugin-vuex-4.5.17.tgz#eb6f597c775f3c847bf5a638ad65a0d03c11dcbf" + integrity sha512-ck/ju2T2dmPKLWK/5QctNJs9SCb+eSZbbmr8neFkMc7GlbXw6qLWw5v3Vpd4KevdQA8QuQOA1pjUmzpCiU/mYQ== -"@vue/cli-service@~4.5.15": - version "4.5.15" - resolved "https://registry.yarnpkg.com/@vue/cli-service/-/cli-service-4.5.15.tgz#0e9a186d51550027d0e68e95042077eb4d115b45" - integrity sha512-sFWnLYVCn4zRfu45IcsIE9eXM0YpDV3S11vlM2/DVbIPAGoYo5ySpSof6aHcIvkeGsIsrHFpPHzNvDZ/efs7jA== +"@vue/cli-service@~4.5.17": + version "4.5.17" + resolved "https://registry.yarnpkg.com/@vue/cli-service/-/cli-service-4.5.17.tgz#6f796056363b70b69065d95815ac170b7772d0c6" + integrity sha512-MqfkRYIcIUACe3nYlzNrYstJTWRXHlIqh6JCkbWbdnXWN+IfaVdlG8zw5Q0DVcSdGvkevUW7zB4UhtZB4uyAcA== dependencies: "@intervolga/optimize-cssnano-plugin" "^1.0.5" "@soda/friendly-errors-webpack-plugin" "^1.7.1" @@ -1320,10 +1336,10 @@ "@types/minimist" "^1.2.0" "@types/webpack" "^4.0.0" "@types/webpack-dev-server" "^3.11.0" - "@vue/cli-overlay" "^4.5.15" - "@vue/cli-plugin-router" "^4.5.15" - "@vue/cli-plugin-vuex" "^4.5.15" - "@vue/cli-shared-utils" "^4.5.15" + "@vue/cli-overlay" "^4.5.17" + "@vue/cli-plugin-router" "^4.5.17" + "@vue/cli-plugin-vuex" "^4.5.17" + "@vue/cli-shared-utils" "^4.5.17" "@vue/component-compiler-utils" "^3.1.2" "@vue/preload-webpack-plugin" "^1.1.0" "@vue/web-component-wrapper" "^1.2.0" @@ -1372,17 +1388,17 @@ optionalDependencies: vue-loader-v16 "npm:vue-loader@^16.1.0" -"@vue/cli-shared-utils@^4.5.15": - version "4.5.15" - resolved "https://registry.yarnpkg.com/@vue/cli-shared-utils/-/cli-shared-utils-4.5.15.tgz#dba3858165dbe3465755f256a4890e69084532d6" - integrity sha512-SKaej9hHzzjKSOw1NlFmc6BSE0vcqUQMQiv1cxQ2DhVyy4QxZXBmzmiLBUBe+hYZZs1neXW7n//udeN9bCAY+Q== +"@vue/cli-shared-utils@^4.5.17": + version "4.5.17" + resolved "https://registry.yarnpkg.com/@vue/cli-shared-utils/-/cli-shared-utils-4.5.17.tgz#bb4aac8b816036cf5c0adf3af3cc1cb9c425501e" + integrity sha512-VoFNdxvTW4vZu3ne+j1Mf7mU99J2SAoRVn9XPrsouTUUJablglM8DASk7Ixhsh6ymyL/W9EADQFR6Pgj8Ujjuw== dependencies: + "@achrinza/node-ipc" "9.2.2" "@hapi/joi" "^15.0.1" chalk "^2.4.2" execa "^1.0.0" launch-editor "^2.2.1" lru-cache "^5.1.1" - node-ipc "^9.1.1" open "^6.3.0" ora "^3.4.0" read-pkg "^5.1.1" @@ -2210,10 +2226,10 @@ builtin-status-codes@^3.0.0: resolved "https://registry.yarnpkg.com/builtin-status-codes/-/builtin-status-codes-3.0.0.tgz#85982878e21b98e1c66425e03d0174788f569ee8" integrity sha1-hZgoeOIbmOHGZCXgPQF0eI9Wnug= -bulma@^0.9.3: - version "0.9.3" - resolved "https://registry.yarnpkg.com/bulma/-/bulma-0.9.3.tgz#ddccb7436ebe3e21bf47afe01d3c43a296b70243" - integrity sha512-0d7GNW1PY4ud8TWxdNcP6Cc8Bu7MxcntD/RRLGWuiw/s0a9P+XlH/6QoOIrmbj6o8WWJzJYhytiu9nFjTszk1g== +bulma@^0.9.4: + version "0.9.4" + resolved "https://registry.yarnpkg.com/bulma/-/bulma-0.9.4.tgz#0ca8aeb1847a34264768dba26a064c8be72674a1" + integrity sha512-86FlT5+1GrsgKbPLRRY7cGDg8fsJiP/jzTqXXVqiUZZ2aZT8uemEOHlU1CDU+TxklPEZ11HZNNWclRBBecP4CQ== bytes@3.0.0: version "3.0.0" @@ -2773,10 +2789,10 @@ core-js@^2.4.0: resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.6.12.tgz#d9333dfa7b065e347cc5682219d6f690859cc2ec" integrity sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ== -core-js@^3.21.1: - version "3.21.1" - resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.21.1.tgz#f2e0ddc1fc43da6f904706e8e955bc19d06a0d94" - integrity sha512-FRq5b/VMrWlrmCzwRrpDYNxyHP9BcAZC+xHJaqTgIE5091ZV1NTmyh0sGOg5XqpnHvR0svdy0sv1gWA1zmhxig== +core-js@^3.22.7: + version "3.22.7" + resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.22.7.tgz#8d6c37f630f6139b8732d10f2c114c3f1d00024f" + integrity sha512-Jt8SReuDKVNZnZEzyEQT5eK6T2RRCXkfTq7Lo09kpm+fHjgGewSbNjV+Wt4yZMhPDdzz2x1ulI5z/w4nxpBseg== core-js@^3.6.5: version "3.15.2" @@ -3339,7 +3355,7 @@ duplexify@^3.4.2, duplexify@^3.6.0: readable-stream "^2.0.0" stream-shift "^1.0.0" -easy-stack@^1.0.1: +easy-stack@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/easy-stack/-/easy-stack-1.0.1.tgz#8afe4264626988cabb11f3c704ccd0c835411066" integrity sha512-wK2sCs4feiiJeFXn3zvY0p41mdU5VUgbgs1rNsc/y5ngFUijdWd+iIN8eoyuZHKB8xN6BL4PdWmzqFmxNg6V2w== @@ -5066,13 +5082,6 @@ js-message@1.0.7: resolved "https://registry.yarnpkg.com/js-message/-/js-message-1.0.7.tgz#fbddd053c7a47021871bb8b2c95397cc17c20e47" integrity sha512-efJLHhLjIyKRewNS9EGZ4UpI8NguuL6fKkhRxVuMmrGV2xN/0APGdQYwLFky5w9naebSZ0OwAGp0G6/2Cg90rA== -js-queue@2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/js-queue/-/js-queue-2.0.2.tgz#0be590338f903b36c73d33c31883a821412cd482" - integrity sha512-pbKLsbCfi7kriM3s1J4DDCo7jQkI58zPLHi0heXPzPlj0hjUsm+FesPUbE0DSbIVIK503A36aUBoCN7eMFedkA== - dependencies: - easy-stack "^1.0.1" - js-tokens@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" @@ -5745,15 +5754,6 @@ node-forge@^0.10.0: resolved "https://registry.yarnpkg.com/node-forge/-/node-forge-0.10.0.tgz#32dea2afb3e9926f02ee5ce8794902691a676bf3" integrity sha512-PPmu8eEeG9saEUvI97fm4OYxXVB6bFvyNTyiUOBichBpFG8A1Ljw3bY62+5oOjDEMHRnd0Y7HQ+x7uzxOzC6JA== -node-ipc@^9.1.1: - version "9.2.1" - resolved "https://registry.yarnpkg.com/node-ipc/-/node-ipc-9.2.1.tgz#b32f66115f9d6ce841dc4ec2009d6a733f98bb6b" - integrity sha512-mJzaM6O3xHf9VT8BULvJSbdVbmHUKRNOH7zDDkCrA1/T+CVjq2WVIDfLt0azZRXpgArJtl3rtmEozrbXPZ9GaQ== - dependencies: - event-pubsub "4.3.0" - js-message "1.0.7" - js-queue "2.0.2" - node-libs-browser@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/node-libs-browser/-/node-libs-browser-2.2.1.tgz#b64f513d18338625f90346d27b0d235e631f6425" From f64278d41d9850461871c1c7908f0c35cbca05cd Mon Sep 17 00:00:00 2001 From: Pierre <397503+bemble@users.noreply.github.com> Date: Mon, 30 May 2022 17:03:28 +0200 Subject: [PATCH 015/435] feat(connectivity): change query parameter to change connectivity Always use timestamp as query parameter instead of alive --- src/components/ConnectivityChecker.vue | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/components/ConnectivityChecker.vue b/src/components/ConnectivityChecker.vue index 0d7e79f..f2be652 100644 --- a/src/components/ConnectivityChecker.vue +++ b/src/components/ConnectivityChecker.vue @@ -56,7 +56,8 @@ export default { // extra check to make sure we're not offline let that = this; - return fetch(window.location.href + "?alive", { + const aliveCheckUrl = window.location.href + "?t="+(new Date().valueOf()); + return fetch(aliveCheckUrl, { method: "HEAD", cache: "no-store", redirect: "manual" @@ -64,7 +65,7 @@ export default { .then(function (response) { // opaqueredirect means request has been redirected, to auth provider probably if ((response.type === "opaqueredirect" && !response.ok) || [401, 403].indexOf(response.status) != -1) { - window.location.href = window.location.href + "?t="+(new Date().valueOf()); + window.location.href = aliveCheckUrl; } that.offline = !response.ok; }) From 132e9a0df516b50c854178ccb726cf9d9dc514fa Mon Sep 17 00:00:00 2001 From: Pierre <397503+bemble@users.noreply.github.com> Date: Mon, 30 May 2022 17:04:21 +0200 Subject: [PATCH 016/435] feat(auth): do not handle redirection in getConfig It will be handled by connectivity checker --- src/App.vue | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/App.vue b/src/App.vue index 515177e..a60c242 100644 --- a/src/App.vue +++ b/src/App.vue @@ -231,13 +231,7 @@ export default { }, getConfig: function (path = "assets/config.yml") { return fetch(path).then((response) => { - if (response.redirected) { - // This allows to work with authentication proxies. - window.location.href = response.url; - return; - } - - if (response.status == 404) { + if (response.status == 404 || response.redirected) { this.configNotFound = true; return {}; } From 95249e11255beb8b85f904c54429b353fca40b9e Mon Sep 17 00:00:00 2001 From: Pierre <397503+bemble@users.noreply.github.com> Date: Mon, 30 May 2022 17:04:41 +0200 Subject: [PATCH 017/435] doc(auth): add auth proxy documentation --- docs/configuration.md | 3 ++- docs/troubleshooting.md | 6 ++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/docs/configuration.md b/docs/configuration.md index 84a7ea7..c240077 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -25,7 +25,8 @@ header: true # Set to false to hide the header footer: '

Created with ❤️ with bulma, vuejs & font awesome // Fork me on

' # set false if you want to hide it. columns: "3" # "auto" or number (must be a factor of 12: 1, 2, 3, 4, 6, 12) -connectivityCheck: true # whether you want to display a message when the apps are not accessible anymore (VPN disconnected for example) +connectivityCheck: true # whether you want to display a message when the apps are not accessible anymore (VPN disconnected for example). + # You should set it to true when using an authentication proxy, it also reloads the page when a redirection is detected when checking connectivity. # Optional: Proxy / hosting option proxy: diff --git a/docs/troubleshooting.md b/docs/troubleshooting.md index 649e5a6..10d6c2d 100644 --- a/docs/troubleshooting.md +++ b/docs/troubleshooting.md @@ -17,3 +17,9 @@ To resolve this, you can either: * Host all your target service under the same domain & port. * Modify the target server configuration so that the response of the server included following header- `Access-Control-Allow-Origin: *` (). It might be an option in the targeted service, otherwise depending on how the service is hosted, the proxy or web server can seamlessly add it. * Use a cors proxy server like [`cors-container`](https://github.com/imjacobclark/cors-container), [`cors-anywhere`](https://github.com/Rob--W/cors-anywhere) or many others. + +## I am using an authentication proxy and homer says I am offline + +This should be a configuration issue. +* Make sure the option `connectivityCheck` is set to `true` in configuration. +* Check your proxy configuration, the expected behavior is to redirect user using a 302 to the login page when user is not authenticated. From fb668b6a3c1f8e0130c55d0539db1335d15a96cf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 1 Jun 2022 17:08:51 +0000 Subject: [PATCH 018/435] Bump eventsource from 1.1.0 to 1.1.1 Bumps [eventsource](https://github.com/EventSource/eventsource) from 1.1.0 to 1.1.1. - [Release notes](https://github.com/EventSource/eventsource/releases) - [Changelog](https://github.com/EventSource/eventsource/blob/master/HISTORY.md) - [Commits](https://github.com/EventSource/eventsource/compare/v1.1.0...v1.1.1) --- updated-dependencies: - dependency-name: eventsource dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index e21871d..5b8ab11 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3678,9 +3678,9 @@ events@^3.0.0: integrity sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q== eventsource@^1.0.7: - version "1.1.0" - resolved "https://registry.yarnpkg.com/eventsource/-/eventsource-1.1.0.tgz#00e8ca7c92109e94b0ddf32dac677d841028cfaf" - integrity sha512-VSJjT5oCNrFvCS6igjzPAt5hBzQ2qPBFIbJ03zLI9SE0mxwZpMw6BfJrbFHm1a141AavMEB8JHmBhWAd66PfCg== + version "1.1.1" + resolved "https://registry.yarnpkg.com/eventsource/-/eventsource-1.1.1.tgz#4544a35a57d7120fba4fa4c86cb4023b2c09df2f" + integrity sha512-qV5ZC0h7jYIAOhArFJgSfdyz6rALJyb270714o7ZtNnw2WSJ+eexhKtE0O8LYPRsHZHf2osHKZBxGPvm3kPkCA== dependencies: original "^1.0.0" From 10f6f123e86ca571c99a232a43f7ea920fde9894 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 5 Jun 2022 21:50:28 +0200 Subject: [PATCH 019/435] Lint run --- src/components/ConnectivityChecker.vue | 11 +++++++---- vue.config.js | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/src/components/ConnectivityChecker.vue b/src/components/ConnectivityChecker.vue index f2be652..2b3e47b 100644 --- a/src/components/ConnectivityChecker.vue +++ b/src/components/ConnectivityChecker.vue @@ -35,7 +35,7 @@ export default { window.addEventListener( "online", function () { - that.checkOffline(); + that.checkOffline(); }, false ); @@ -56,15 +56,18 @@ export default { // extra check to make sure we're not offline let that = this; - const aliveCheckUrl = window.location.href + "?t="+(new Date().valueOf()); + const aliveCheckUrl = window.location.href + "?t=" + new Date().valueOf(); return fetch(aliveCheckUrl, { method: "HEAD", cache: "no-store", - redirect: "manual" + redirect: "manual", }) .then(function (response) { // opaqueredirect means request has been redirected, to auth provider probably - if ((response.type === "opaqueredirect" && !response.ok) || [401, 403].indexOf(response.status) != -1) { + if ( + (response.type === "opaqueredirect" && !response.ok) || + [401, 403].indexOf(response.status) != -1 + ) { window.location.href = aliveCheckUrl; } that.offline = !response.ok; diff --git a/vue.config.js b/vue.config.js index 1645c2f..82329d8 100644 --- a/vue.config.js +++ b/vue.config.js @@ -27,6 +27,6 @@ module.exports = { }, }, devServer: { - disableHostCheck: true + disableHostCheck: true, }, }; From 1327cc0ab0e78d0cfc2fe11fddca8cc32dae8ac6 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Mon, 6 Jun 2022 21:45:10 +0200 Subject: [PATCH 020/435] Configuring automatically generated release notes --- .github/release.yml | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 .github/release.yml diff --git a/.github/release.yml b/.github/release.yml new file mode 100644 index 0000000..906d71f --- /dev/null +++ b/.github/release.yml @@ -0,0 +1,8 @@ +changelog: + exclude: + authors: + - dependabot + categories: + - title: Main changes + labels: + - "*" \ No newline at end of file From a43fe354ec6e6226a41ecfd98cd0343a54e5a428 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 12 Jun 2022 16:15:54 +0200 Subject: [PATCH 021/435] Simplified & updated CI/CD --- .github/workflows/dockerhub.yml | 44 +++++++++++++++++++++++++++ .github/workflows/integration.yml | 2 +- .github/workflows/release.yml | 24 ++++----------- Dockerfile.arm32v7 | 49 ------------------------------- Dockerfile.arm64v8 | 49 ------------------------------- hooks/post_push | 8 ----- hooks/pre_build | 8 ----- 7 files changed, 51 insertions(+), 133 deletions(-) create mode 100644 .github/workflows/dockerhub.yml delete mode 100644 Dockerfile.arm32v7 delete mode 100644 Dockerfile.arm64v8 delete mode 100644 hooks/post_push delete mode 100644 hooks/pre_build diff --git a/.github/workflows/dockerhub.yml b/.github/workflows/dockerhub.yml new file mode 100644 index 0000000..68e3d67 --- /dev/null +++ b/.github/workflows/dockerhub.yml @@ -0,0 +1,44 @@ +# Build & publish docker images +name: Dockerhub + +on: + push: + tags: [v*] + branches: [ main ] + + +jobs: + dockerhub: + runs-on: ubuntu-latest + steps: + - + name: Checkout + uses: actions/checkout@v3 + - + name: Set up QEMU + uses: docker/setup-qemu-action@v2 + - + name: Set up Docker Buildx + id: buildx + uses: docker/setup-buildx-action@v2 + - + name: Login to Docker Hub + uses: docker/login-action@v2 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + - + name: Set tag name + run: | + if [[ ${{ github.ref_type }} == "tag" ]]; then + echo "IMAGE_TAG=${{ github.ref_name }}" >> $GITHUB_ENV + else + echo "IMAGE_TAG=latest" >> $GITHUB_ENV + fi + - + name: Build and push + uses: docker/build-push-action@v3 + with: + push: true + tags: b4bz/buildx-test:${{env.IMAGE_TAG}} + platforms: linux/amd64,linux/arm/v7,linux/arm64 \ No newline at end of file diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml index 8d1a7ad..257f758 100644 --- a/.github/workflows/integration.yml +++ b/.github/workflows/integration.yml @@ -20,7 +20,7 @@ jobs: # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Use Node.js ${{ matrix.node-version }} uses: actions/setup-node@v2 with: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 886556d..62c15a8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,7 +10,7 @@ jobs: name: Upload Release Asset runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - name: Build project run: | yarn install @@ -20,21 +20,9 @@ jobs: run: zip -r ../homer.zip ./* - name: Create Release id: create_release - uses: actions/create-release@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + uses: softprops/action-gh-release@v1 with: - tag_name: ${{ github.ref }} - release_name: Release ${{ github.ref }} - draft: false - prerelease: false - - name: Upload Release Asset - id: upload-release-asset - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - asset_path: ./homer.zip - asset_name: homer.zip - asset_content_type: application/zip + token: ${{ secrets.GITHUB_TOKEN }} + generate_release_notes: true + files: | + homer.zip \ No newline at end of file diff --git a/Dockerfile.arm32v7 b/Dockerfile.arm32v7 deleted file mode 100644 index 270d7b5..0000000 --- a/Dockerfile.arm32v7 +++ /dev/null @@ -1,49 +0,0 @@ -# build stage -FROM node:lts-alpine as build-stage - -WORKDIR /app - -COPY package*.json ./ -RUN yarn install --frozen-lockfile - -COPY . . -RUN yarn build - -# Multi arch build support -FROM alpine as qemu - -ARG QEMU_VERSION="v4.2.0-7" - -RUN wget https://github.com/multiarch/qemu-user-static/releases/download/${QEMU_VERSION}/qemu-arm-static && chmod +x qemu-arm-static - -# production stage -FROM arm32v7/alpine:3.16 - -COPY --from=qemu qemu-arm-static /usr/bin/ - -ENV GID 1000 -ENV UID 1000 -ENV PORT 8080 -ENV SUBFOLDER "/_" -ENV INIT_ASSETS 1 - -RUN addgroup -S lighttpd -g ${GID} && adduser -D -S -u ${UID} lighttpd lighttpd && \ - apk add -U --no-cache lighttpd && \ - rm /usr/bin/qemu-arm-static - -WORKDIR /www - -COPY lighttpd.conf /lighttpd.conf -COPY entrypoint.sh /entrypoint.sh -COPY --from=build-stage --chown=${UID}:${GID} /app/dist /www/ -COPY --from=build-stage --chown=${UID}:${GID} /app/dist/assets /www/default-assets - -USER ${UID}:${GID} - -HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ - CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 - -EXPOSE ${PORT} -VOLUME /www/assets - -CMD ["lighttpd", "-D", "-f", "/lighttpd.conf"] diff --git a/Dockerfile.arm64v8 b/Dockerfile.arm64v8 deleted file mode 100644 index f940bde..0000000 --- a/Dockerfile.arm64v8 +++ /dev/null @@ -1,49 +0,0 @@ -# build stage -FROM node:lts-alpine as build-stage - -WORKDIR /app - -COPY package*.json ./ -RUN yarn install --frozen-lockfile - -COPY . . -RUN yarn build - -# Multi arch build support -FROM alpine as qemu - -ARG QEMU_VERSION="v4.2.0-7" - -RUN wget https://github.com/multiarch/qemu-user-static/releases/download/${QEMU_VERSION}/qemu-aarch64-static && chmod +x qemu-aarch64-static - -# production stage -FROM arm64v8/alpine:3.16 - -COPY --from=qemu qemu-aarch64-static /usr/bin/ - -ENV GID 1000 -ENV UID 1000 -ENV PORT 8080 -ENV SUBFOLDER "/_" -ENV INIT_ASSETS 1 - -RUN addgroup -S lighttpd -g ${GID} && adduser -D -S -u ${UID} lighttpd lighttpd && \ - apk add -U --no-cache lighttpd && \ - rm /usr/bin/qemu-aarch64-static - -WORKDIR /www - -COPY lighttpd.conf /lighttpd.conf -COPY entrypoint.sh /entrypoint.sh -COPY --from=build-stage --chown=${UID}:${GID} /app/dist /www/ -COPY --from=build-stage --chown=${UID}:${GID} /app/dist/assets /www/default-assets - -USER ${UID}:${GID} - -HEALTHCHECK --interval=30s --timeout=5s --retries=3 \ - CMD wget --no-verbose --tries=1 --spider http://127.0.0.1:${PORT}/ || exit 1 - -EXPOSE ${PORT} -VOLUME /www/assets - -CMD ["lighttpd", "-D", "-f", "/lighttpd.conf"] diff --git a/hooks/post_push b/hooks/post_push deleted file mode 100644 index 3d4830d..0000000 --- a/hooks/post_push +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash - -IFS='-' read -r TAG string <<< "$DOCKER_TAG" - -docker manifest create b4bz/homer:$TAG b4bz/homer:$TAG-amd64 b4bz/homer:$TAG-arm32v7 b4bz/homer:$TAG-arm64v8 -docker manifest annotate b4bz/homer:$TAG b4bz/homer:$TAG-arm32v7 --os linux --arch arm -docker manifest annotate b4bz/homer:$TAG b4bz/homer:$TAG-arm64v8 --os linux --arch arm64 --variant v8 -docker manifest push --purge b4bz/homer:$TAG diff --git a/hooks/pre_build b/hooks/pre_build deleted file mode 100644 index bc1b6fe..0000000 --- a/hooks/pre_build +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash - -# Update to docker-ee 18.x for manifests -apt-get -y update -apt-get -y --only-upgrade install docker-ee -# Register qemu-*-static for all supported processors except the -# current one, but also remove all registered binfmt_misc before -docker run --rm --privileged multiarch/qemu-user-static:register --reset \ No newline at end of file From a01c40d4b34e1c4afea5b8e52f69e9a328b51d33 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 12 Jun 2022 21:46:11 +0200 Subject: [PATCH 022/435] fix repository name --- .github/workflows/dockerhub.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dockerhub.yml b/.github/workflows/dockerhub.yml index 68e3d67..65a5c99 100644 --- a/.github/workflows/dockerhub.yml +++ b/.github/workflows/dockerhub.yml @@ -40,5 +40,5 @@ jobs: uses: docker/build-push-action@v3 with: push: true - tags: b4bz/buildx-test:${{env.IMAGE_TAG}} + tags: b4bz/homer:${{env.IMAGE_TAG}} platforms: linux/amd64,linux/arm/v7,linux/arm64 \ No newline at end of file From 7315b9e28cff36a897f99d2da5da92f7c511b458 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 23 Jun 2022 03:33:16 +0000 Subject: [PATCH 023/435] Bump shell-quote from 1.7.2 to 1.7.3 Bumps [shell-quote](https://github.com/substack/node-shell-quote) from 1.7.2 to 1.7.3. - [Release notes](https://github.com/substack/node-shell-quote/releases) - [Changelog](https://github.com/substack/node-shell-quote/blob/master/CHANGELOG.md) - [Commits](https://github.com/substack/node-shell-quote/compare/v1.7.2...1.7.3) --- updated-dependencies: - dependency-name: shell-quote dependency-type: indirect ... Signed-off-by: dependabot[bot] --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index 5b8ab11..99899e4 100644 --- a/yarn.lock +++ b/yarn.lock @@ -7404,9 +7404,9 @@ shebang-regex@^3.0.0: integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== shell-quote@^1.6.1: - version "1.7.2" - resolved "https://registry.yarnpkg.com/shell-quote/-/shell-quote-1.7.2.tgz#67a7d02c76c9da24f99d20808fcaded0e0e04be2" - integrity sha512-mRz/m/JVscCrkMyPqHc/bczi3OQHkLTqXHEFu0zDhK/qfv3UcOA4SVmRCLmos4bhjr9ekVQubj/R7waKapmiQg== + version "1.7.3" + resolved "https://registry.yarnpkg.com/shell-quote/-/shell-quote-1.7.3.tgz#aa40edac170445b9a431e17bb62c0b881b9c4123" + integrity sha512-Vpfqwm4EnqGdlsBFNmHhxhElJYrdfcxPThu+ryKS5J8L/fhAwLazFZtq+S+TWZ9ANj2piSQLGj6NQg+lKPmxrw== signal-exit@^3.0.0, signal-exit@^3.0.2: version "3.0.3" From 1b9a3f197526c69921d37e84f1eeff27dc42df8e Mon Sep 17 00:00:00 2001 From: toa Date: Thu, 23 Jun 2022 19:07:55 +0200 Subject: [PATCH 024/435] feat: add custom service Healthchecks * refs #474 --- docs/customservices.md | 14 +++ src/components/services/Healhchecks.vue | 115 ++++++++++++++++++++++++ 2 files changed, 129 insertions(+) create mode 100644 src/components/services/Healhchecks.vue diff --git a/docs/customservices.md b/docs/customservices.md index efe8ca4..3f14f8c 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -19,6 +19,7 @@ within Homer: + [Emby / Jellyfin](#emby--jellyfin) + [Uptime Kuma](#uptime-kuma) + [Tautulli](#tautulli) ++ [Healthchecks](#healthchecks) If you experiencing any issue, please have a look to the [troubleshooting](troubleshooting.md) page. @@ -223,3 +224,16 @@ endpoint pointing to Tautulli! type: "Tautulli" apikey: "MY-SUPER-SECRET-API-KEY" ``` + +## Healthchecks + +This service displays information about the configured status checks from the Healthchecks application. +Two lines are needed in the config.yml : + +```yaml + type: "Healthchecks" + apikey: "01234deb70424befb1f4ef6a23456789" +``` + +The url must be the root url of the Healthchecks application. +The Healthchecks API key can be found in Settings > API Access > API key (read-only). The key is needed to access Healthchecks API. diff --git a/src/components/services/Healhchecks.vue b/src/components/services/Healhchecks.vue new file mode 100644 index 0000000..c60f241 --- /dev/null +++ b/src/components/services/Healhchecks.vue @@ -0,0 +1,115 @@ + + + + + From 71d929a55a50b4b5fa1bc6524b74f6fd5dab814c Mon Sep 17 00:00:00 2001 From: Nuno Goncalves Date: Wed, 29 Jun 2022 10:58:05 +0100 Subject: [PATCH 025/435] Fix wrong config.yml path Path to config.yml when checking for existing configuration was wrong and it will never be found --- entrypoint.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/entrypoint.sh b/entrypoint.sh index eba1cb2..48df1e6 100644 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -3,7 +3,7 @@ PERMISSION_ERROR="Check assets directory permissions & docker user or skip default assets install by setting the INIT_ASSETS env var to 0" # Default assets & exemple configuration installation if possible. -if [[ "${INIT_ASSETS}" == "1" ]] && [[ ! -f "/www/config.yml" ]]; then +if [[ "${INIT_ASSETS}" == "1" ]] && [[ ! -f "/www/assets/config.yml" ]]; then echo "No configuration found, installing default config & assets" if [[ ! -w "/www/assets/" ]]; then echo "Assets directory not writable. $PERMISSION_ERROR" && exit 1; fi From b5bf977402c4bedd7c2ca771592635ac8dd07dca Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Wed, 29 Jun 2022 23:02:10 +0200 Subject: [PATCH 026/435] Adding permissions configuration information. --- README.md | 21 +++++++-------------- docs/troubleshooting.md | 26 +++++++++++++++++++++++++- 2 files changed, 32 insertions(+), 15 deletions(-) diff --git a/README.md b/README.md index 5a08483..ea93f4f 100644 --- a/README.md +++ b/README.md @@ -65,9 +65,9 @@ ## Getting started -Homer is a full static html/js dashboard, generated from the source in `/src` using webpack. It's meant to be served by an HTTP server, **it will not work if you open dist/index.html directly over file:// protocol**. +Homer is a full static html/js dashboard, based on a simple yaml configuration file. See [documentation](docs/configuration.md) for information about the configuration (`assets/config.yml`) options. -See [documentation](docs/configuration.md) for information about the configuration (`assets/config.yml`) options. +It's meant to be served by an HTTP server, **it will not work if you open the index.html directly over file:// protocol**. ### Using docker @@ -79,7 +79,9 @@ docker run -d \ b4bz/homer:latest ``` -Environment variables: +The container will run using a user uid and gid 1000. Add `--user :` to the docker command to adjust it. Make sure this match the ownership of your assets directory. + +**Environment variables:** * **`INIT_ASSETS`** (default: `1`) Install example configuration file & assets (favicons, ...) to help you get started. @@ -87,18 +89,9 @@ Install example configuration file & assets (favicons, ...) to help you get star * **`SUBFOLDER`** (default: `null`) If you would like to host Homer in a subfolder, (ex: *http://my-domain/**homer***), set this to the subfolder path (ex `/homer`). +#### With docker-compose -### Using docker-compose - -The `docker-compose.yml` file must be edited to match your needs. -You probably want to set the port mapping and volume binding (equivalent to `-p` and `-v` arguments): - -```yaml -volumes: - - /your/local/assets/:/www/assets -ports: - - 8080:8080 -``` +A [`docker-compose.yml`](docker-compose.yml) file is available as an example. It must be edited to match your needs. You probably want to adjust the port mapping and volume binding (equivalent to `-p` and `-v` arguments). Then launch the container: diff --git a/docs/troubleshooting.md b/docs/troubleshooting.md index 10d6c2d..33b8fb7 100644 --- a/docs/troubleshooting.md +++ b/docs/troubleshooting.md @@ -1,8 +1,32 @@ # Troubleshooting +## My docker container refuse to start / is stuck at restarting. + +You might be facing a permission issue. First of all, check your container logs (adjust the container name if necessary): + +```sh +$ docker logs homer +[...] +Assets directory not writable. Check assets directory permissions & docker user or skip default assets install by setting the INIT_ASSETS env var to 0 +``` + +In this case you need to make sure your mounted assests directory have the same GID / UID the container user have (default 1000:1000), and that the read and write permission is granted for the user or the group. + +You can either: +- Update your assets directory permissions (ex: `chown -R 1000:1000 /your/assets/folder/`, `chmod -R u+rw /your/assets/folder/`) +- Change the docker user by using the `--user` arguments with docker cli or `user: 1000:1000` with docker compose. + +⚠️ Notes: + +- **Do not** use env var to set the GID / UID of the user running container. Use the Docker `user` option. +- **Do not** use 0:0 as a user value, it would be a security risk, and it's not guaranty to work. + +Check this [thread](https://github.com/bastienwirtz/homer/issues/459) for more information about debugging +permission issues. + ## My custom service card doesn't work, nothing appears or offline status is displayed (pi-hole, sonarr, ping, ...) -You might by facing a [CORS](https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS) (Cross Origin Request Sharing) issue. +You might be facing a [CORS](https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS) (Cross Origin Request Sharing) issue. It happens when the targeted service is hosted on a different domain or port. Web browsers will not allow to fetch information from a different site without explicit permissions (the targeted service must include a special `Access-Control-Allow-Origin: *` HTTP headers). From 263be7806cb50a8badf6f6dac250a674ca14dc72 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sat, 2 Jul 2022 14:29:34 +0200 Subject: [PATCH 027/435] Prevent webserver restart on clock jump --- lighttpd.conf | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/lighttpd.conf b/lighttpd.conf index 32e14da..f62657a 100644 --- a/lighttpd.conf +++ b/lighttpd.conf @@ -1,10 +1,11 @@ include "/etc/lighttpd/mime-types.conf" -server.port = env.PORT -server.modules = ( "mod_alias" ) -server.username = "lighttpd" -server.groupname = "lighttpd" -server.document-root = "/www" -alias.url = ( env.SUBFOLDER => "/www" ) -server.indexfiles = ("index.html") -server.follow-symlink = "enable" +server.port = env.PORT +server.modules = ( "mod_alias" ) +server.username = "lighttpd" +server.groupname = "lighttpd" +server.document-root = "/www" +alias.url = ( env.SUBFOLDER => "/www" ) +server.indexfiles = ("index.html") +server.follow-symlink = "enable" +server.feature-flags += ( "server.clock-jump-restart" => 0 ) \ No newline at end of file From 95c589ba71d80ed0073158bbb6f81ec449b058d6 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sat, 2 Jul 2022 14:51:08 +0200 Subject: [PATCH 028/435] Vue-cli update --- package.json | 8 ++--- yarn.lock | 90 ++++++++++++++++++++++++++-------------------------- 2 files changed, 49 insertions(+), 49 deletions(-) diff --git a/package.json b/package.json index a6d5fbf..8af02e9 100644 --- a/package.json +++ b/package.json @@ -16,10 +16,10 @@ "vue": "^2.6.14" }, "devDependencies": { - "@vue/cli-plugin-babel": "~4.5.17", - "@vue/cli-plugin-eslint": "~4.5.17", - "@vue/cli-plugin-pwa": "~4.5.17", - "@vue/cli-service": "~4.5.17", + "@vue/cli-plugin-babel": "~4.5.19", + "@vue/cli-plugin-eslint": "~4.5.19", + "@vue/cli-plugin-pwa": "~4.5.19", + "@vue/cli-service": "~4.5.19", "@vue/eslint-config-prettier": "^6.0.0", "babel-eslint": "^10.1.0", "eslint": "^6.7.2", diff --git a/yarn.lock b/yarn.lock index 99899e4..3342547 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1189,10 +1189,10 @@ lodash.kebabcase "^4.1.1" svg-tags "^1.0.0" -"@vue/babel-preset-app@^4.5.17": - version "4.5.17" - resolved "https://registry.yarnpkg.com/@vue/babel-preset-app/-/babel-preset-app-4.5.17.tgz#09c64eedfe868bfa3121fc12a59138518f830bde" - integrity sha512-iFv9J3F5VKUPcbx+TqW5qhGmAVyXQxPRpKpPOuTLFIVTzg+iwJnrqVbL4kJU5ECGDxPESW2oCVgxv9bTlDPu7w== +"@vue/babel-preset-app@^4.5.19": + version "4.5.19" + resolved "https://registry.yarnpkg.com/@vue/babel-preset-app/-/babel-preset-app-4.5.19.tgz#baee457da0065c016f74fac4149f7c97631ba5a7" + integrity sha512-VCNRiAt2P/bLo09rYt3DLe6xXUMlhJwrvU18Ddd/lYJgC7s8+wvhgYs+MTx4OiAXdu58drGwSBO9SPx7C6J82Q== dependencies: "@babel/core" "^7.11.0" "@babel/helper-compilation-targets" "^7.9.6" @@ -1274,61 +1274,61 @@ "@vue/babel-plugin-transform-vue-jsx" "^1.2.1" camelcase "^5.0.0" -"@vue/cli-overlay@^4.5.17": - version "4.5.17" - resolved "https://registry.yarnpkg.com/@vue/cli-overlay/-/cli-overlay-4.5.17.tgz#4e0e24b7c3b71ff86de86f532821fd3abb48d10c" - integrity sha512-QKKp66VbMg+X8Qh0wgXSwgxLfxY7EIkZkV6bZ6nFqBx8xtaJQVDbTL+4zcUPPA6nygbIcQ6gvTinNEqIqX6FUQ== +"@vue/cli-overlay@^4.5.19": + version "4.5.19" + resolved "https://registry.yarnpkg.com/@vue/cli-overlay/-/cli-overlay-4.5.19.tgz#d1206f7802bcba1d9c307695b54091df996db804" + integrity sha512-GdxvNSmOw7NHIazCO8gTK+xZbaOmScTtxj6eHVeMbYpDYVPJ+th3VMLWNpw/b6uOjwzzcyKlA5dRQ1DAb+gF/g== -"@vue/cli-plugin-babel@~4.5.17": - version "4.5.17" - resolved "https://registry.yarnpkg.com/@vue/cli-plugin-babel/-/cli-plugin-babel-4.5.17.tgz#8c468e32ef6546f843201770a294bf599689e004" - integrity sha512-6kZuc3PdoUvGAnndUq6+GqjIXn3bqdTR8lOcAb1BH2b4N7IKGlmzcipALGS23HLVMAvDgNuUS7vf0unin9j2cg== +"@vue/cli-plugin-babel@~4.5.19": + version "4.5.19" + resolved "https://registry.yarnpkg.com/@vue/cli-plugin-babel/-/cli-plugin-babel-4.5.19.tgz#288b32e69f0191a77369e88f071c0cd8036edfa7" + integrity sha512-8ebXzaMW9KNTMAN6+DzkhFsjty1ieqT7hIW5Lbk4v30Qhfjkms7lBWyXPGkoq+wAikXFa1Gnam2xmWOBqDDvWg== dependencies: "@babel/core" "^7.11.0" - "@vue/babel-preset-app" "^4.5.17" - "@vue/cli-shared-utils" "^4.5.17" + "@vue/babel-preset-app" "^4.5.19" + "@vue/cli-shared-utils" "^4.5.19" babel-loader "^8.1.0" cache-loader "^4.1.0" thread-loader "^2.1.3" webpack "^4.0.0" -"@vue/cli-plugin-eslint@~4.5.17": - version "4.5.17" - resolved "https://registry.yarnpkg.com/@vue/cli-plugin-eslint/-/cli-plugin-eslint-4.5.17.tgz#7667bf87bdfdb39faeb3baed58657622354a17bc" - integrity sha512-bVNDP+SuWcuJrBMc+JLaKvlxx25XKIlZBa+zzFnxhHZlwPZ7CeBD3e2wnsygJyPoKgDZcZwDgmEz1BZzMEjsNw== +"@vue/cli-plugin-eslint@~4.5.19": + version "4.5.19" + resolved "https://registry.yarnpkg.com/@vue/cli-plugin-eslint/-/cli-plugin-eslint-4.5.19.tgz#d1f908b5d079f2902dc23301290e4dd8176f204c" + integrity sha512-53sa4Pu9j5KajesFlj494CcO8vVo3e3nnZ1CCKjGGnrF90id1rUeepcFfz5XjwfEtbJZp2x/NoX/EZE6zCzSFQ== dependencies: - "@vue/cli-shared-utils" "^4.5.17" + "@vue/cli-shared-utils" "^4.5.19" eslint-loader "^2.2.1" globby "^9.2.0" inquirer "^7.1.0" webpack "^4.0.0" yorkie "^2.0.0" -"@vue/cli-plugin-pwa@~4.5.17": - version "4.5.17" - resolved "https://registry.yarnpkg.com/@vue/cli-plugin-pwa/-/cli-plugin-pwa-4.5.17.tgz#73b2f9dd1203de46761a9843e972966e2717fe87" - integrity sha512-IaODWmj5eQjv97ne0CTOgPZA8QmVS7zYX64C+SivWPw0uevJAhNUdDHgyrUODP7fEfyufKliStLMQJTowohGNQ== +"@vue/cli-plugin-pwa@~4.5.19": + version "4.5.19" + resolved "https://registry.yarnpkg.com/@vue/cli-plugin-pwa/-/cli-plugin-pwa-4.5.19.tgz#6b18c62746d3893af5338f62a2ee7b726b2ff4bb" + integrity sha512-3WLmI+ky1xejrvBK6mPiu3du16iZDOF/OHV0EDgdwuBPmmg6w4TvV0Ho4iWMK+BWY68qxIadhqX23JvFfFLvOg== dependencies: - "@vue/cli-shared-utils" "^4.5.17" + "@vue/cli-shared-utils" "^4.5.19" webpack "^4.0.0" workbox-webpack-plugin "^4.3.1" -"@vue/cli-plugin-router@^4.5.17": - version "4.5.17" - resolved "https://registry.yarnpkg.com/@vue/cli-plugin-router/-/cli-plugin-router-4.5.17.tgz#9de189a7a8740817cde2a4e57aade14552ff68c3" - integrity sha512-9r9CSwqv2+39XHQPDZJ0uaTtTP7oe0Gx17m7kBhHG3FA7R7AOSk2aVzhHZmDRhzlOxjx9kQSvrOSMfUG0kV4dQ== +"@vue/cli-plugin-router@^4.5.19": + version "4.5.19" + resolved "https://registry.yarnpkg.com/@vue/cli-plugin-router/-/cli-plugin-router-4.5.19.tgz#a7feea7024b83a0af77fc940d1637d3ce2f92e1f" + integrity sha512-3icGzH1IbVYmMMsOwYa0lal/gtvZLebFXdE5hcQJo2mnTwngXGMTyYAzL56EgHBPjbMmRpyj6Iw9k4aVInVX6A== dependencies: - "@vue/cli-shared-utils" "^4.5.17" + "@vue/cli-shared-utils" "^4.5.19" -"@vue/cli-plugin-vuex@^4.5.17": - version "4.5.17" - resolved "https://registry.yarnpkg.com/@vue/cli-plugin-vuex/-/cli-plugin-vuex-4.5.17.tgz#eb6f597c775f3c847bf5a638ad65a0d03c11dcbf" - integrity sha512-ck/ju2T2dmPKLWK/5QctNJs9SCb+eSZbbmr8neFkMc7GlbXw6qLWw5v3Vpd4KevdQA8QuQOA1pjUmzpCiU/mYQ== +"@vue/cli-plugin-vuex@^4.5.19": + version "4.5.19" + resolved "https://registry.yarnpkg.com/@vue/cli-plugin-vuex/-/cli-plugin-vuex-4.5.19.tgz#2452de58eb66ed873852bea45e6e06b57d842b47" + integrity sha512-DUmfdkG3pCdkP7Iznd87RfE9Qm42mgp2hcrNcYQYSru1W1gX2dG/JcW8bxmeGSa06lsxi9LEIc/QD1yPajSCZw== -"@vue/cli-service@~4.5.17": - version "4.5.17" - resolved "https://registry.yarnpkg.com/@vue/cli-service/-/cli-service-4.5.17.tgz#6f796056363b70b69065d95815ac170b7772d0c6" - integrity sha512-MqfkRYIcIUACe3nYlzNrYstJTWRXHlIqh6JCkbWbdnXWN+IfaVdlG8zw5Q0DVcSdGvkevUW7zB4UhtZB4uyAcA== +"@vue/cli-service@~4.5.19": + version "4.5.19" + resolved "https://registry.yarnpkg.com/@vue/cli-service/-/cli-service-4.5.19.tgz#5f6513128f426be0ee9a7d03155c23a6f23f8d42" + integrity sha512-+Wpvj8fMTCt9ZPOLu5YaLkFCQmB4MrZ26aRmhhKiCQ/4PMoL6mLezfqdt6c+m2htM+1WV5RunRo+0WHl2DfwZA== dependencies: "@intervolga/optimize-cssnano-plugin" "^1.0.5" "@soda/friendly-errors-webpack-plugin" "^1.7.1" @@ -1336,10 +1336,10 @@ "@types/minimist" "^1.2.0" "@types/webpack" "^4.0.0" "@types/webpack-dev-server" "^3.11.0" - "@vue/cli-overlay" "^4.5.17" - "@vue/cli-plugin-router" "^4.5.17" - "@vue/cli-plugin-vuex" "^4.5.17" - "@vue/cli-shared-utils" "^4.5.17" + "@vue/cli-overlay" "^4.5.19" + "@vue/cli-plugin-router" "^4.5.19" + "@vue/cli-plugin-vuex" "^4.5.19" + "@vue/cli-shared-utils" "^4.5.19" "@vue/component-compiler-utils" "^3.1.2" "@vue/preload-webpack-plugin" "^1.1.0" "@vue/web-component-wrapper" "^1.2.0" @@ -1388,10 +1388,10 @@ optionalDependencies: vue-loader-v16 "npm:vue-loader@^16.1.0" -"@vue/cli-shared-utils@^4.5.17": - version "4.5.17" - resolved "https://registry.yarnpkg.com/@vue/cli-shared-utils/-/cli-shared-utils-4.5.17.tgz#bb4aac8b816036cf5c0adf3af3cc1cb9c425501e" - integrity sha512-VoFNdxvTW4vZu3ne+j1Mf7mU99J2SAoRVn9XPrsouTUUJablglM8DASk7Ixhsh6ymyL/W9EADQFR6Pgj8Ujjuw== +"@vue/cli-shared-utils@^4.5.19": + version "4.5.19" + resolved "https://registry.yarnpkg.com/@vue/cli-shared-utils/-/cli-shared-utils-4.5.19.tgz#cc389b1de1b05073804c0fe9b4b083b928ef6130" + integrity sha512-JYpdsrC/d9elerKxbEUtmSSU6QRM60rirVubOewECHkBHj+tLNznWq/EhCjswywtePyLaMUK25eTqnTSZlEE+g== dependencies: "@achrinza/node-ipc" "9.2.2" "@hapi/joi" "^15.0.1" From cbbed6346a437e6b9f05f646f1df0c77d2fb36eb Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sat, 4 Jun 2022 22:40:48 +0200 Subject: [PATCH 029/435] Migrate to VueJS 3 --- .browserslistrc | 3 - .eslintrc.cjs | 14 + .eslintrc.js | 15 - babel.config.js | 3 - index.html | 13 + package.json | 33 +- public/index.html | 18 - src/App.vue | 6 +- src/assets/app.scss | 2 +- src/components/SearchInput.vue | 2 +- src/components/Service.vue | 5 +- src/main.js | 16 +- vite.config.js | 15 + vue.config.js | 32 - yarn.lock | 9889 +++++++++----------------------- 15 files changed, 2672 insertions(+), 7394 deletions(-) delete mode 100644 .browserslistrc create mode 100644 .eslintrc.cjs delete mode 100644 .eslintrc.js delete mode 100644 babel.config.js create mode 100644 index.html delete mode 100644 public/index.html create mode 100644 vite.config.js delete mode 100644 vue.config.js diff --git a/.browserslistrc b/.browserslistrc deleted file mode 100644 index 214388f..0000000 --- a/.browserslistrc +++ /dev/null @@ -1,3 +0,0 @@ -> 1% -last 2 versions -not dead diff --git a/.eslintrc.cjs b/.eslintrc.cjs new file mode 100644 index 0000000..ed2ab70 --- /dev/null +++ b/.eslintrc.cjs @@ -0,0 +1,14 @@ +/* eslint-env node */ +require("@rushstack/eslint-patch/modern-module-resolution"); + +module.exports = { + root: true, + extends: [ + "plugin:vue/vue3-essential", + "eslint:recommended", + "@vue/eslint-config-prettier", + ], + env: { + "vue/setup-compiler-macros": true, + }, +}; diff --git a/.eslintrc.js b/.eslintrc.js deleted file mode 100644 index 2ac7400..0000000 --- a/.eslintrc.js +++ /dev/null @@ -1,15 +0,0 @@ -module.exports = { - root: true, - env: { - node: true, - }, - extends: ["plugin:vue/essential", "eslint:recommended", "@vue/prettier"], - parserOptions: { - parser: "babel-eslint", - }, - rules: { - "no-console": "off", - "no-debugger": process.env.NODE_ENV === "production" ? "warn" : "off", - "vue/require-v-for-key": "off", - }, -}; diff --git a/babel.config.js b/babel.config.js deleted file mode 100644 index 162a3ea..0000000 --- a/babel.config.js +++ /dev/null @@ -1,3 +0,0 @@ -module.exports = { - presets: ["@vue/cli-plugin-babel/preset"], -}; diff --git a/index.html b/index.html new file mode 100644 index 0000000..030a6ff --- /dev/null +++ b/index.html @@ -0,0 +1,13 @@ + + + + + + + Vite App + + +
+ + + diff --git a/package.json b/package.json index 8af02e9..9efa8a1 100644 --- a/package.json +++ b/package.json @@ -2,34 +2,29 @@ "name": "homer", "version": "21.09.1", "scripts": { - "serve": "vue-cli-service serve", - "build": "vue-cli-service build", - "lint": "vue-cli-service lint" + "dev": "vite", + "build": "vite build", + "preview": "vite preview --port 5050", + "lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs --fix --ignore-path .gitignore" }, "dependencies": { "@fortawesome/fontawesome-free": "^6.1.1", "bulma": "^0.9.4", - "core-js": "^3.22.7", "js-yaml": "^4.1.0", "lodash.merge": "^4.6.2", "register-service-worker": "^1.7.2", - "vue": "^2.6.14" + "vue": "^3.2.33" }, "devDependencies": { - "@vue/cli-plugin-babel": "~4.5.19", - "@vue/cli-plugin-eslint": "~4.5.19", - "@vue/cli-plugin-pwa": "~4.5.19", - "@vue/cli-service": "~4.5.19", - "@vue/eslint-config-prettier": "^6.0.0", - "babel-eslint": "^10.1.0", - "eslint": "^6.7.2", - "eslint-plugin-prettier": "^3.3.1", - "eslint-plugin-vue": "^6.2.2", - "prettier": "^2.2.1", - "raw-loader": "^4.0.2", - "sass": "^1.26.5", - "sass-loader": "^8.0.2", - "vue-template-compiler": "^2.6.12" + "@rushstack/eslint-patch": "^1.1.0", + "@vitejs/plugin-vue": "^2.3.1", + "@vue/cli-plugin-pwa": "^5.0.4", + "@vue/eslint-config-prettier": "^7.0.0", + "eslint": "^8.5.0", + "eslint-plugin-vue": "^8.2.0", + "prettier": "^2.5.1", + "sass": "^1.52.2", + "vite": "^2.9.9" }, "license": "Apache-2.0" } diff --git a/public/index.html b/public/index.html deleted file mode 100644 index e38d444..0000000 --- a/public/index.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - - - <%= htmlWebpackPlugin.options.title %> - - - -
- - - diff --git a/src/App.vue b/src/App.vue index 664867f..43ba322 100644 --- a/src/App.vue +++ b/src/App.vue @@ -140,8 +140,8 @@ diff --git a/src/components/services/UptimeKuma.vue b/src/components/services/UptimeKuma.vue index 3be53b8..5117a05 100644 --- a/src/components/services/UptimeKuma.vue +++ b/src/components/services/UptimeKuma.vue @@ -99,6 +99,7 @@ export default { }, }, created() { + /* eslint-disable */ this.item.url = `${this.item.url}/status/${this.dashboard}`; this.fetchStatus(); }, diff --git a/vite.config.js b/vite.config.js index 0400b78..262f311 100644 --- a/vite.config.js +++ b/vite.config.js @@ -1,4 +1,4 @@ -import { VitePWA } from 'vite-plugin-pwa' +import { VitePWA } from "vite-plugin-pwa"; import { fileURLToPath, URL } from "url"; import { defineConfig } from "vite"; @@ -10,30 +10,30 @@ export default defineConfig({ assetsDir: "resources", }, plugins: [ - vue(), - VitePWA({ - registerType: 'autoUpdate', + vue(), + VitePWA({ + registerType: "autoUpdate", useCredentials: true, manifestFilename: "assets/manifest.json", manifest: { - name: 'Homer dashboard', - short_name: 'Homer', - description: 'Home Server Dashboard', - theme_color: '#3367D6', + name: "Homer dashboard", + short_name: "Homer", + description: "Home Server Dashboard", + theme_color: "#3367D6", icons: [ { - src: 'pwa-192x192.png', - sizes: '192x192', - type: 'image/png' + src: "pwa-192x192.png", + sizes: "192x192", + type: "image/png", }, { - src: 'pwa-512x512.png', - sizes: '512x512', - type: 'image/png' - } + src: "pwa-512x512.png", + sizes: "512x512", + type: "image/png", + }, ], }, - }) + }), ], resolve: { alias: { @@ -41,4 +41,3 @@ export default defineConfig({ }, }, }); - From 5890d4193253a7cc204a3e44e94ffdce3fb68ff5 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 3 Jul 2022 22:09:14 +0200 Subject: [PATCH 033/435] Missing eof --- lighttpd.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lighttpd.conf b/lighttpd.conf index f62657a..fa0cfb2 100644 --- a/lighttpd.conf +++ b/lighttpd.conf @@ -8,4 +8,4 @@ server.document-root = "/www" alias.url = ( env.SUBFOLDER => "/www" ) server.indexfiles = ("index.html") server.follow-symlink = "enable" -server.feature-flags += ( "server.clock-jump-restart" => 0 ) \ No newline at end of file +server.feature-flags += ( "server.clock-jump-restart" => 0 ) From 73d52dbd380471100a6a1eca341b0e98aa5c692e Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 3 Jul 2022 22:43:01 +0200 Subject: [PATCH 034/435] Add missing icons --- index.html | 1 + public/logo.png | Bin 0 -> 27504 bytes vite.config.js | 6 ++++++ 3 files changed, 7 insertions(+) create mode 100644 public/logo.png diff --git a/index.html b/index.html index e908198..58f531c 100644 --- a/index.html +++ b/index.html @@ -4,6 +4,7 @@ + Homer diff --git a/public/logo.png b/public/logo.png new file mode 100644 index 0000000000000000000000000000000000000000..18347215da770d140e1eb8466692a733e483d34d GIT binary patch literal 27504 zcmWh!19V(n5N=~9jn&vT8Z~Ha+qR8%W1HKkv28WBv$5IO+UVc^ytC(>^Ui$V%$@h{ z%)N7GBb61UP>~3cK7IOxDkCkS`svf>vHyPvaF8d#zmeA=H#k!{DTz-X|6h4sCCQ&Y z*-^_#h^l+9o@INvt3PJ940A{F0yoZRUL41UjGbZEmY0hWsmNgv$kmOlPrBsXXTOL= z#2tgMRTSWZk2mf%*}EPYzDt)*+`hA82=GA3+;(t!Np2nep5}Ln6Ka246K;90?j=JI zi!3D^B)X)!jSr$yuJFg49H*Wu_NNHmQZ(INlbP@nh~##nZRpU)q#dVrDb~lt8>4o4 zEOQ;F7Hy*;(PMs=zyRUp3T!zCBEvykyr;Hu`p4*VNAhoECLk8|cwr(ir%T_z3|!W1pcyy#9ISw%uD?7>pni;8^JDOZMAM%!9=;~Pq4t0|o~ zFAzE5N1Nzos^30S=9QFTD4ZCAB%|&jbKp^?3Gswo!dL~)UYR<1WGRx&L{-8_7g8kI zT+61+zDlUXVrR0nY$#Rv7_>Nm3}I|LwPYwmn>_Ic4rUwUkl9Ch#z;0&BvWaEwAi48 zaMCwC7*V>e9vvgWjr}a@)|yXrdTn)%-(hWu_Dcj5M_krcgBO2r6H`sk8qw zbdA)+2&p%X%k2UFg)scagvLk}lVYTq>kz|CEds)bI^%Cf?>Jr3%p7mP#B~BcQ6y4) z4dVU9)h5V@05DKx3E9$=|NGpcYPPgniG9F7%W|gwGk+ivvY%y zK!(7x7pz_0jW^x+xI3Dh&otMBxqNE~r4r;cep%=SD>{?X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b568fe6 100644 --- a/vite.config.js +++ b/vite.config.js @@ -31,6 +31,12 @@ export default defineConfig({ sizes: "512x512", type: "image/png", }, + { + src: 'pwa-512x512.png', + sizes: '512x512', + type: 'image/png', + purpose: 'any maskable' + } ], }, }), From 2f1aff4dc5115232b16faf20e85ac4a90677661a Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Mon, 4 Jul 2022 22:17:41 +0200 Subject: [PATCH 035/435] Fix icons path --- vite.config.js | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/vite.config.js b/vite.config.js index b568fe6..46fe909 100644 --- a/vite.config.js +++ b/vite.config.js @@ -22,21 +22,15 @@ export default defineConfig({ theme_color: "#3367D6", icons: [ { - src: "pwa-192x192.png", + src: "./icons/pwa-192x192.png", sizes: "192x192", type: "image/png", }, { - src: "pwa-512x512.png", + src: "./icons/pwa-512x512.png", sizes: "512x512", type: "image/png", }, - { - src: 'pwa-512x512.png', - sizes: '512x512', - type: 'image/png', - purpose: 'any maskable' - } ], }, }), From 4b639b1c100fc579922457bd4d3e9f52d29749e4 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Mon, 11 Jul 2022 20:58:57 +0200 Subject: [PATCH 036/435] Uniform workflow yaml style --- .github/workflows/integration.yml | 15 +++++++++++---- .github/workflows/release.yml | 13 +++++++++---- 2 files changed, 20 insertions(+), 8 deletions(-) diff --git a/.github/workflows/integration.yml b/.github/workflows/integration.yml index 257f758..258e77e 100644 --- a/.github/workflows/integration.yml +++ b/.github/workflows/integration.yml @@ -20,12 +20,19 @@ jobs: # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ steps: - - uses: actions/checkout@v3 - - name: Use Node.js ${{ matrix.node-version }} + - + name: Checkout + uses: actions/checkout@v3 + - + name: Use Node.js ${{ matrix.node-version }} uses: actions/setup-node@v2 with: node-version: ${{ matrix.node-version }} cache: 'yarn' - - run: yarn install - - run: yarn lint + - + name: install dependencies + run: yarn install + - + name: Check code style & potentential issues + run: yarn lint diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 62c15a8..66bfb5b 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -10,15 +10,20 @@ jobs: name: Upload Release Asset runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - name: Build project + - + name: Checkout + uses: actions/checkout@v3 + - + name: Build project run: | yarn install yarn build - - name: Create artifact + - + name: Create artifact working-directory: "dist" run: zip -r ../homer.zip ./* - - name: Create Release + - + name: Create Release id: create_release uses: softprops/action-gh-release@v1 with: From 5609315fe77da5441a9c3dda8d92c0ffe9f1bf17 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Mon, 11 Jul 2022 21:00:01 +0200 Subject: [PATCH 037/435] Simplify index & fix logo path --- index.html | 8 +++----- public/{ => assets/icons}/logo.svg | 0 2 files changed, 3 insertions(+), 5 deletions(-) rename public/{ => assets/icons}/logo.svg (100%) diff --git a/index.html b/index.html index 58f531c..a08e126 100644 --- a/index.html +++ b/index.html @@ -2,13 +2,11 @@ - - - - + + + Homer -
diff --git a/public/logo.svg b/public/assets/icons/logo.svg similarity index 100% rename from public/logo.svg rename to public/assets/icons/logo.svg From ce391840e58d04f74ca1d411a4686801fc1a1a70 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Mon, 11 Jul 2022 22:07:15 +0200 Subject: [PATCH 038/435] Documentation update --- docs/configuration.md | 27 ++------------------------- docs/customservices.md | 6 ++++++ docs/development.md | 4 ++-- 3 files changed, 10 insertions(+), 27 deletions(-) diff --git a/docs/configuration.md b/docs/configuration.md index a4da08b..10edf71 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -152,7 +152,7 @@ services: # background: red # optional color for card to set color directly without custom stylesheet ``` -View [Custom Services](customservices.md) for details about all available custom services (like PiHole) and how to configure them. +View **[Custom Services](customservices.md)** for details about all available custom services (like `PiHole`) and how to configure them. If you choose to fetch message information from an endpoint, the output format should be as follows (or you can [custom map fields as shown in tips-and-tricks](./tips-and-tricks.md#mapping-fields)): @@ -180,27 +180,4 @@ You can read the [bulma modifiers page](https://bulma.io/documentation/modifiers ## PWA Icons -In order to easily generate all required icon preset for the PWA to work, a tool like [vue-pwa-asset-generator](https://www.npmjs.com/package/vue-pwa-asset-generator) can be used: - -```bash -npx vue-pwa-asset-generator -a {your_512x512_source_png} -o {your_output_folder} -``` - -## Supported services - -Currently the following services are supported for showing quick infos on the card. They can be used by setting the type to one of the following values at the item. - -- PiHole -- AdGuardHome -- PaperlessNG -- Mealie - -## Additional configuration - -### Paperless - -For Paperless you need an API-Key which you have to store at the item in the field `apikey`. - -### Mealie - -First off make sure to remove an existing `subtitle` as it will take precedence if set. Setting `type: "Mealie"` will then show the number of recipes Mealie is keeping organized or the planned meal for today if one is planned. You will have to set an API key in the field `apikey` which can be created in your Mealie installation. +See icons documentation [here](https://github.com/bastienwirtz/homer/blob/main/public/assets/icons/README.md). diff --git a/docs/customservices.md b/docs/customservices.md index efe8ca4..6a54400 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -19,6 +19,7 @@ within Homer: + [Emby / Jellyfin](#emby--jellyfin) + [Uptime Kuma](#uptime-kuma) + [Tautulli](#tautulli) ++ [Mealie](#mealie) If you experiencing any issue, please have a look to the [troubleshooting](troubleshooting.md) page. @@ -223,3 +224,8 @@ endpoint pointing to Tautulli! type: "Tautulli" apikey: "MY-SUPER-SECRET-API-KEY" ``` + +## Mealie + +First off make sure to remove an existing `subtitle` as it will take precedence if set. +Setting `type: "Mealie"` will then show the number of recipes Mealie is keeping organized or the planned meal for today if one is planned. You will have to set an API key in the field `apikey` which can be created in your Mealie installation. diff --git a/docs/development.md b/docs/development.md index a22ae0b..85781a1 100644 --- a/docs/development.md +++ b/docs/development.md @@ -5,11 +5,11 @@ If you want to contribute to Homer, please read the [contributing guidelines](ht ```sh # Using yarn (recommended) yarn install -yarn serve +yarn dev # **OR** Using npm npm install -npm run serve +npm run dev ``` ## Custom services From 9582b1871ac63d1e625ccf6c221bd1248a1c9d03 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Mon, 11 Jul 2022 22:07:48 +0200 Subject: [PATCH 039/435] Fix search widget --- package.json | 8 ++++---- src/App.vue | 16 +++++++++------- yarn.lock | 35 +++++++++++++++++++++-------------- 3 files changed, 34 insertions(+), 25 deletions(-) diff --git a/package.json b/package.json index 8643569..bd19439 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "homer", - "version": "22.07.1", + "version": "22.07.2", "scripts": { "dev": "vite", "build": "vite build", @@ -19,11 +19,11 @@ "@vitejs/plugin-vue": "^2.3.1", "@vue/eslint-config-prettier": "^7.0.0", "eslint": "^8.5.0", - "eslint-plugin-vue": "^9.1.1", + "eslint-plugin-vue": "^9.2.0", "prettier": "^2.5.1", "sass": "^1.52.2", - "vite": "^2.9.9", - "vite-plugin-pwa": "^0.12.2" + "vite": "^2.9.14", + "vite-plugin-pwa": "^0.12.3" }, "license": "Apache-2.0" } diff --git a/src/App.vue b/src/App.vue index 43ba322..4120fe5 100644 --- a/src/App.vue +++ b/src/App.vue @@ -49,10 +49,10 @@
@@ -255,11 +255,12 @@ export default { }); }, matchesFilter: function (item) { + const needle = this.filter?.toLowerCase(); return ( - item.name.toLowerCase().includes(this.filter) || - (item.subtitle && item.subtitle.toLowerCase().includes(this.filter)) || - (item.tag && item.tag.toLowerCase().includes(this.filter)) || - (item.keywords && item.keywords.toLowerCase().includes(this.filter)) + item.name.toLowerCase().includes(needle) || + (item.subtitle && item.subtitle.toLowerCase().includes(needle)) || + (item.tag && item.tag.toLowerCase().includes(needle)) || + (item.keywords && item.keywords.toLowerCase().includes(needle)) ); }, navigateToFirstService: function (target) { @@ -271,6 +272,7 @@ export default { } }, filterServices: function (filter) { + console.log(filter); this.filter = filter; if (!filter) { diff --git a/yarn.lock b/yarn.lock index b22f2ec..de6a390 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1715,10 +1715,10 @@ eslint-plugin-prettier@^4.0.0: dependencies: prettier-linter-helpers "^1.0.0" -eslint-plugin-vue@^9.1.1: - version "9.1.1" - resolved "https://registry.yarnpkg.com/eslint-plugin-vue/-/eslint-plugin-vue-9.1.1.tgz#341f7533cb041958455138834341d5be01f9f327" - integrity sha512-W9n5PB1X2jzC7CK6riG0oAcxjmKrjTF6+keL1rni8n57DZeilx/Fulz+IRJK3lYseLNAygN0I62L7DvioW40Tw== +eslint-plugin-vue@^9.2.0: + version "9.2.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-vue/-/eslint-plugin-vue-9.2.0.tgz#b7ca02b2ce8218b7586346440fc61c2655db353a" + integrity sha512-W2hc+NUXoce8sZtWgZ45miQTy6jNyuSdub5aZ1IBune4JDeAyzucYX0TzkrQ1jMO52sNUDYlCIHDoaNePe0p5g== dependencies: eslint-utils "^3.0.0" natural-compare "^1.4.0" @@ -2679,13 +2679,20 @@ rollup-plugin-terser@^7.0.0: serialize-javascript "^4.0.0" terser "^5.0.0" -rollup@^2.43.1, rollup@^2.59.0, rollup@^2.75.5: +rollup@^2.43.1, rollup@^2.59.0: version "2.75.7" resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.75.7.tgz#221ff11887ae271e37dcc649ba32ce1590aaa0b9" integrity sha512-VSE1iy0eaAYNCxEXaleThdFXqZJ42qDBatAwrfnPlENEZ8erQ+0LYX4JXOLPceWfZpV1VtZwZ3dFCuOZiSyFtQ== optionalDependencies: fsevents "~2.3.2" +rollup@^2.75.7: + version "2.76.0" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.76.0.tgz#c69fe03db530ac53fcb9523b3caa0d3c0b9491a1" + integrity sha512-9jwRIEY1jOzKLj3nsY/yot41r19ITdQrhs+q3ggNWhr9TQgduHqANvPpS32RNpzGklJu3G1AJfvlZLi/6wFgWA== + optionalDependencies: + fsevents "~2.3.2" + run-parallel@^1.1.9: version "1.2.0" resolved "https://registry.yarnpkg.com/run-parallel/-/run-parallel-1.2.0.tgz#66d1368da7bdf921eb9d95bd1a9229e7f21a43ee" @@ -3005,22 +3012,22 @@ v8-compile-cache@^2.0.3: resolved "https://registry.yarnpkg.com/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz#2de19618c66dc247dcfb6f99338035d8245a2cee" integrity sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA== -vite-plugin-pwa@^0.12.2: - version "0.12.2" - resolved "https://registry.yarnpkg.com/vite-plugin-pwa/-/vite-plugin-pwa-0.12.2.tgz#d0ec1cd3088260bdc5bf2b10ba753def0b8f3280" - integrity sha512-XK2oi1YZkoc1J8fyerNYxyh/yfb+INdrdOW/mOOD5DBLq7jVPxHQuncIhqiREbGOMlY/xMe9CSE7QZ9xIAEf7A== +vite-plugin-pwa@^0.12.3: + version "0.12.3" + resolved "https://registry.yarnpkg.com/vite-plugin-pwa/-/vite-plugin-pwa-0.12.3.tgz#acf2913ae85a4d39c13ae4b948307f3dd5506fa8" + integrity sha512-gmYdIVXpmBuNjzbJFPZFzxWYrX4lHqwMAlOtjmXBbxApiHjx9QPXKQPJjSpeTeosLKvVbNcKSAAhfxMda0QVNQ== dependencies: debug "^4.3.4" fast-glob "^3.2.11" pretty-bytes "^6.0.0" - rollup "^2.75.5" + rollup "^2.75.7" workbox-build "^6.5.3" workbox-window "^6.5.3" -vite@^2.9.9: - version "2.9.13" - resolved "https://registry.yarnpkg.com/vite/-/vite-2.9.13.tgz#859cb5d4c316c0d8c6ec9866045c0f7858ca6abc" - integrity sha512-AsOBAaT0AD7Mhe8DuK+/kE4aWYFMx/i0ZNi98hJclxb4e0OhQcZYUrvLjIaQ8e59Ui7txcvKMiJC1yftqpQoDw== +vite@^2.9.14: + version "2.9.14" + resolved "https://registry.yarnpkg.com/vite/-/vite-2.9.14.tgz#c438324c6594afd1050df3777da981dee988bb1b" + integrity sha512-P/UCjSpSMcE54r4mPak55hWAZPlyfS369svib/gpmz8/01L822lMPOJ/RYW6tLCe1RPvMvOsJ17erf55bKp4Hw== dependencies: esbuild "^0.14.27" postcss "^8.4.13" From eb030922866f1e753162d99ea6b25a4f4e941b05 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Tue, 12 Jul 2022 14:07:10 +0200 Subject: [PATCH 040/435] Fix theming issue & subfolder hosting --- index.html | 2 +- src/assets/app.scss | 2 +- src/main.js | 2 +- vite.config.js | 1 + 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/index.html b/index.html index a08e126..5a0014c 100644 --- a/index.html +++ b/index.html @@ -9,7 +9,7 @@ Homer -
+
diff --git a/src/assets/app.scss b/src/assets/app.scss index 5102f93..d112482 100644 --- a/src/assets/app.scss +++ b/src/assets/app.scss @@ -13,7 +13,7 @@ text-overflow: ellipsis; } -html, body, body #app { +html, body, body #app-mount, body #app { height: 100%; background-color: var(--background); } diff --git a/src/main.js b/src/main.js index 164d290..a1d7b47 100644 --- a/src/main.js +++ b/src/main.js @@ -10,4 +10,4 @@ app.component("DynamicStyle", (_props, context) => { return h("style", {}, context.slots); }); -app.mount("#app"); +app.mount("#app-mount"); diff --git a/vite.config.js b/vite.config.js index 46fe909..cee8727 100644 --- a/vite.config.js +++ b/vite.config.js @@ -6,6 +6,7 @@ import vue from "@vitejs/plugin-vue"; // https://vitejs.dev/config/ export default defineConfig({ + base: "", build: { assetsDir: "resources", }, From a46bede230afd80b3fbf562f4d5d7491155e3835 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Tue, 12 Jul 2022 22:26:45 +0200 Subject: [PATCH 041/435] Small fixes --- src/components/DarkMode.vue | 2 +- src/components/Message.vue | 1 - src/components/SettingToggle.vue | 5 ++++- src/components/services/OpenWeather.vue | 4 ++-- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/components/DarkMode.vue b/src/components/DarkMode.vue index 677238a..4318c22 100644 --- a/src/components/DarkMode.vue +++ b/src/components/DarkMode.vue @@ -1,6 +1,6 @@ + @@ -43,7 +50,8 @@ memoryUsed: 0, diskUsed: 0, cpuUsed: 0, - error: false + error: false, + loading: true }), created() { this.fetchStatus(); @@ -71,8 +79,10 @@ this.vms.total += vms.data.length; this.vms.running += vms.data.filter( i => i.status === 'running' ).length; this.error = false; + this.loading = false; } catch(err) { console.log(err); + this.loading = false; this.error = true; } }, From 4fe179c53364c21eae3e5507aa7140a701287214 Mon Sep 17 00:00:00 2001 From: luixal Date: Tue, 11 Oct 2022 19:47:48 +0200 Subject: [PATCH 064/435] Small refactor to remove one redundant line. --- src/components/services/Proxmox.vue | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/components/services/Proxmox.vue b/src/components/services/Proxmox.vue index 092d077..1d2c2c9 100644 --- a/src/components/services/Proxmox.vue +++ b/src/components/services/Proxmox.vue @@ -79,12 +79,11 @@ this.vms.total += vms.data.length; this.vms.running += vms.data.filter( i => i.status === 'running' ).length; this.error = false; - this.loading = false; } catch(err) { console.log(err); - this.loading = false; this.error = true; } + this.loading = false; }, }, }; From 96da0c7ce034ce7c6e2e1a4a65ee63e3edcb574c Mon Sep 17 00:00:00 2001 From: luixal Date: Wed, 12 Oct 2022 23:36:37 +0200 Subject: [PATCH 065/435] Fixes typo. --- docs/customservices.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/customservices.md b/docs/customservices.md index 417459e..3c4f5ad 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -259,7 +259,7 @@ The API Token (or the user asigned to that token if not separated permissions is It is highly recommended that you create and API Token with only these permissions on a read-only mode. -If you get errors, they will be shown on browser's dev console. Main issues tend to be CORS related as Proxmox does not include CORS headers and you have to desploy it behind a reverse proxy and make the proxy add this headers. +If you get errors, they will be shown on browser's dev console. Main issues tend to be CORS related as Proxmox does not include CORS headers and you have to deploy it behind a reverse proxy and make the proxy add this headers. Configuration example: From 494529f0a95641d82ee64b8a2db89826de64edfd Mon Sep 17 00:00:00 2001 From: luixal Date: Wed, 12 Oct 2022 23:32:37 +0200 Subject: [PATCH 066/435] Adds proxmox data for demo. --- .../api2/json/nodes/node1/qemu/index.html | 1 + .../api2/json/nodes/node1/status/index.html | 44 +++++++++++++++++++ public/assets/config-demo.yml.dist | 9 ++++ 3 files changed, 54 insertions(+) create mode 100644 dummy-data/proxmox/api2/json/nodes/node1/qemu/index.html create mode 100644 dummy-data/proxmox/api2/json/nodes/node1/status/index.html diff --git a/dummy-data/proxmox/api2/json/nodes/node1/qemu/index.html b/dummy-data/proxmox/api2/json/nodes/node1/qemu/index.html new file mode 100644 index 0000000..9ce2e04 --- /dev/null +++ b/dummy-data/proxmox/api2/json/nodes/node1/qemu/index.html @@ -0,0 +1 @@ +{"data":[{"disk":0,"mem":983848043,"cpus":2,"pid":1218,"maxdisk":107374182400,"netin":43863882954,"diskread":0,"diskwrite":0,"name":"HAOS","netout":10426448652,"cpu":0.00879886290177172,"uptime":3390069,"status":"running","maxmem":3221225472,"vmid":100},{"cpu":0.00219971572544293,"name":"debian1","netout":919020028,"vmid":101,"maxmem":4294967296,"uptime":3390064,"status":"running","maxdisk":107374182400,"pid":1295,"cpus":2,"disk":0,"mem":2755160795,"diskread":0,"diskwrite":0,"netin":5105600872}]} \ No newline at end of file diff --git a/dummy-data/proxmox/api2/json/nodes/node1/status/index.html b/dummy-data/proxmox/api2/json/nodes/node1/status/index.html new file mode 100644 index 0000000..72c06b7 --- /dev/null +++ b/dummy-data/proxmox/api2/json/nodes/node1/status/index.html @@ -0,0 +1,44 @@ +{ + "data": { + "swap": { + "free": 8589930496, + "total": 8589930496, + "used": 0 + }, + "cpuinfo": { + "model": "Intel(R) Core(TM) i7-4790 CPU @3.60GHz", + "hvm": "1", + "user_hz": 100, + "sockets": 1, + "cpus": 8, + "flags": "fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid sse4_1 sse4_2 x2apic movbe popcnt aes xsave avx f16c rdrand lahf_lm abm cpuid_fault epb invpcid_single pti tpr_shadow vnmi flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm xsaveopt dtherm ida arat pln pts", + "cores": 4, + "mhz": "4000.000" + }, + "idle": 0, + "memory": { + "used": 6283382784, + "total": 12419133440, + "free": 6135750656 + }, + "rootfs": { + "avail": 22670036992, + "free": 24176627712, + "total": 29148368896, + "used": 4971741184 + }, + "uptime": 3390081, + "ksm": { + "shared": 1079975936 + }, + "cpu": 0.00440286186020914, + "kversion": "Linux 5.15.30-2-pve #1 SMP PVE 5.15.30-3 (Fri, 22 Apr 2022 18: 08: 27+0200)", + "loadavg": [ + "0.00", + "0.01", + "0.04" + ], + "pveversion": "pve-manager/7.2-3/c743d6c1", + "wait": 0.00330214639515685 + } +} \ No newline at end of file diff --git a/public/assets/config-demo.yml.dist b/public/assets/config-demo.yml.dist index 041d287..5bd9bae 100644 --- a/public/assets/config-demo.yml.dist +++ b/public/assets/config-demo.yml.dist @@ -88,3 +88,12 @@ services: url: "#" endpoint: "https://homer-demo-content.netlify.app/pihole" type: "PiHole" + - name: "Proxmox - Node1" + logo: "https://camo.githubusercontent.com/2df2ac41e1b8a1484be236c75e395981b31bfd670eff46b5c182ea0be9475310/68747470733a2f2f7777772e70726f786d6f782e636f6d2f696d616765732f70726f786d6f782f50726f786d6f785f73796d626f6c5f7374616e646172645f6865782e706e67" + type: "Proxmox" + tag: "sys" + url: "https://homer-demo-content.netlify.app/proxmox" + node: "node1" + warning_value: 50 + danger_value: 80 + api_token: "PVEAPIToken=root@pam!monitoring=baaaa46c1-7aee-4f13-b3e5-754d856111a9" From 81c90009b48f22d65bc8b59944b18c9503fc5676 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Thu, 13 Oct 2022 22:23:31 +0200 Subject: [PATCH 067/435] Refine demo content --- dummy-data/README.md | 2 +- dummy-data/proxmox/api2/json/nodes/node1/qemu | 35 +++++++++ .../api2/json/nodes/node1/qemu/index.html | 1 - .../nodes/node1/{status/index.html => status} | 0 public/assets/config-demo.yml.dist | 71 ++++++++++++------- 5 files changed, 80 insertions(+), 29 deletions(-) create mode 100644 dummy-data/proxmox/api2/json/nodes/node1/qemu delete mode 100644 dummy-data/proxmox/api2/json/nodes/node1/qemu/index.html rename dummy-data/proxmox/api2/json/nodes/node1/{status/index.html => status} (100%) diff --git a/dummy-data/README.md b/dummy-data/README.md index deed875..eeff4ec 100644 --- a/dummy-data/README.md +++ b/dummy-data/README.md @@ -11,5 +11,5 @@ The principle is simple: save a sample output of the API used in the service in Example: ``` mkdir pihole -curl http://my-pihile.me/admin/api.php -o pihole/api.php # /admin is omited because for PiHole, the implementation expect it to be in the base url (`url` or `enpoint` property) +curl http://my-pihole.me/admin/api.php -o pihole/api.php # /admin is omited because for PiHole, the implementation expect it to be in the base url (`url` or `enpoint` property) ``` \ No newline at end of file diff --git a/dummy-data/proxmox/api2/json/nodes/node1/qemu b/dummy-data/proxmox/api2/json/nodes/node1/qemu new file mode 100644 index 0000000..35e1d2f --- /dev/null +++ b/dummy-data/proxmox/api2/json/nodes/node1/qemu @@ -0,0 +1,35 @@ +{ + "data": [{ + "disk": 0, + "mem": 983848043, + "cpus": 2, + "pid": 1218, + "maxdisk": 107374182400, + "netin": 43863882954, + "diskread": 0, + "diskwrite": 0, + "name": "HAOS", + "netout": 10426448652, + "cpu": 0.00879886290177172, + "uptime": 3390069, + "status": "running", + "maxmem": 3221225472, + "vmid": 100 + }, { + "cpu": 0.00219971572544293, + "name": "debian1", + "netout": 919020028, + "vmid": 101, + "maxmem": 4294967296, + "uptime": 3390064, + "status": "running", + "maxdisk": 107374182400, + "pid": 1295, + "cpus": 2, + "disk": 0, + "mem": 2755160795, + "diskread": 0, + "diskwrite": 0, + "netin": 5105600872 + }] +} \ No newline at end of file diff --git a/dummy-data/proxmox/api2/json/nodes/node1/qemu/index.html b/dummy-data/proxmox/api2/json/nodes/node1/qemu/index.html deleted file mode 100644 index 9ce2e04..0000000 --- a/dummy-data/proxmox/api2/json/nodes/node1/qemu/index.html +++ /dev/null @@ -1 +0,0 @@ -{"data":[{"disk":0,"mem":983848043,"cpus":2,"pid":1218,"maxdisk":107374182400,"netin":43863882954,"diskread":0,"diskwrite":0,"name":"HAOS","netout":10426448652,"cpu":0.00879886290177172,"uptime":3390069,"status":"running","maxmem":3221225472,"vmid":100},{"cpu":0.00219971572544293,"name":"debian1","netout":919020028,"vmid":101,"maxmem":4294967296,"uptime":3390064,"status":"running","maxdisk":107374182400,"pid":1295,"cpus":2,"disk":0,"mem":2755160795,"diskread":0,"diskwrite":0,"netin":5105600872}]} \ No newline at end of file diff --git a/dummy-data/proxmox/api2/json/nodes/node1/status/index.html b/dummy-data/proxmox/api2/json/nodes/node1/status similarity index 100% rename from dummy-data/proxmox/api2/json/nodes/node1/status/index.html rename to dummy-data/proxmox/api2/json/nodes/node1/status diff --git a/public/assets/config-demo.yml.dist b/public/assets/config-demo.yml.dist index 5bd9bae..153ff6c 100644 --- a/public/assets/config-demo.yml.dist +++ b/public/assets/config-demo.yml.dist @@ -8,7 +8,7 @@ logo: "logo.png" # icon: "fas fa-skull-crossbones" # Optional icon header: true -footer: '

Created with ❤️ with bulma, vuejs & font awesome // Fork me on

' # set false if you want to hide it. +footer: '

Created with ❤️ with Bulma, Vue.js & font awesome // Fork me on

' # set false if you want to hide it. # Optional theme customization theme: default @@ -42,11 +42,9 @@ colors: # Optional message message: - #url: https://b4bz.io style: "is-dark" # See https://bulma.io/documentation/components/message/#colors for styling options. - title: "Demo !" - icon: "fa fa-grin" - content: "This is a dummy homepage demo.
Find more information on github.com/bastienwirtz/homer" + title: "👋 Welcome !" + content: "This demo page shows an overview of Homer possibilities. Feel free to click anywhere!
Find more information on github.com/bastienwirtz/homer" # Optional navbar # links: [] # Allows for navbar (dark mode, layout, and search) without any links @@ -55,9 +53,9 @@ links: icon: "fab fa-github" url: "https://github.com/bastienwirtz/homer" target: "_blank" # optional html a tag target attribute - - name: "Wiki" + - name: "Documentation" icon: "fas fa-book" - url: "https://www.wikipedia.org/" + url: "https://github.com/bastienwirtz/homer/blob/main/README.md#table-of-contents" # this will link to a second homer page that will load config from additional-page.yml and keep default config values as in config.yml file # see url field and assets/additional-page.yml.dist used in this example: - name: "another page!" @@ -68,32 +66,51 @@ links: # First level array represent a group. # Leave only a "items" key if not using group (group name, icon & tagstyle are optional, section separation will not be displayed). services: - - name: "Applications" + - name: "My apps" icon: "fas fa-cloud" items: - - name: "Awesome app" + - name: "Pi-hole" + logo: "https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/pihole.png" + url: "https://pi-hole.net/" + endpoint: "https://homer-demo-content.netlify.app/pihole" + type: "PiHole" + - name: "Proxmox - Node1" + logo: "https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/proxmox.png" + type: "Proxmox" + tag: "sys" + url: "https://www.proxmox.com/en/" + endpoint: "https://homer-demo-content.netlify.app/proxmox" + node: "node1" + warning_value: 50 + danger_value: 80 + api_token: "xxxxxxxxxxxx" + - name: "An awesome app" logo: "assets/tools/sample.png" subtitle: "Bookmark example" tag: "app" keywords: "self hosted reddit" url: "https://www.reddit.com/r/selfhosted/" - target: "_blank" # optional html a tag target attribute - - name: "Another one" - logo: "assets/tools/sample2.png" - subtitle: "Another application" + - name: "Tools" + icon: "fa-solid fa-screwdriver-wrench" + items: + - name: "Example item" + logo: "assets/tools/sample.png" + subtitle: "This another example" tag: "app" + keywords: "demo" url: "#" - - name: "Pi-hole" - logo: "https://cdn.jsdelivr.net/gh/walkxcode/dashboard-icons/png/pihole.png" - url: "#" - endpoint: "https://homer-demo-content.netlify.app/pihole" - type: "PiHole" - - name: "Proxmox - Node1" - logo: "https://camo.githubusercontent.com/2df2ac41e1b8a1484be236c75e395981b31bfd670eff46b5c182ea0be9475310/68747470733a2f2f7777772e70726f786d6f782e636f6d2f696d616765732f70726f786d6f782f50726f786d6f785f73796d626f6c5f7374616e646172645f6865782e706e67" - type: "Proxmox" - tag: "sys" - url: "https://homer-demo-content.netlify.app/proxmox" - node: "node1" - warning_value: 50 - danger_value: 80 - api_token: "PVEAPIToken=root@pam!monitoring=baaaa46c1-7aee-4f13-b3e5-754d856111a9" + target: "_blank" + - name: "interesting links" + icon: "fas fa-solid fa-arrow-up-right-from-square" + items: + - name: "r/selfhosted" + icon: "fa-brands fa-reddit-alien" + subtitle: "Bookmark example" + tag: "reddit" + url: "https://www.reddit.com/r/selfhosted/" + target: "_blank" + - name: "Awesome selfhosted" + icon: "fa-brands fa-github-alt" + subtitle: "Another application" + tag: "awesome-list" + url: "https://github.com/awesome-selfhosted/awesome-selfhosted" From 0800e9ac3cc005aba67461a9f697e7a7cf791ae2 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Fri, 14 Oct 2022 09:22:32 +0200 Subject: [PATCH 068/435] Fix proxmox demo service data loading --- dummy-data/_headers | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dummy-data/_headers b/dummy-data/_headers index 175405b..e26ac79 100644 --- a/dummy-data/_headers +++ b/dummy-data/_headers @@ -1,3 +1,4 @@ /* Content-Type: application/json - Access-Control-Allow-Origin: * \ No newline at end of file + Access-Control-Allow-Origin: https://homer-demo.netlify.app + Access-Control-Allow-Headers: Authorization \ No newline at end of file From 956f38a5dc6b86ccb38c8ecdb3c625d3eb565ebc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sylwester=20Wr=C3=B3blewski?= Date: Sat, 15 Oct 2022 17:16:37 +0200 Subject: [PATCH 069/435] Fixed 'method' not defaulting to HEAD request in Ping functionality --- src/components/services/Ping.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/services/Ping.vue b/src/components/services/Ping.vue index 571c5ad..07bc053 100644 --- a/src/components/services/Ping.vue +++ b/src/components/services/Ping.vue @@ -29,7 +29,7 @@ export default { }, methods: { fetchStatus: async function () { - const method = typeof this.item.method === 'string' ? this.item.method.toUpperCase() : 'unknown'; + const method = typeof this.item.method === 'string' ? this.item.method.toUpperCase() : 'HEAD'; if (!['GET', 'HEAD', 'OPTION'].includes(method)) { console.error(`Ping: ${method} is not a supported HTTP method`); From 52a136e0deba9ab984c68f6d5ac6dc763820cd77 Mon Sep 17 00:00:00 2001 From: Paul Bennett Date: Tue, 25 Oct 2022 21:35:05 +0100 Subject: [PATCH 070/435] Adding my custom theme for homer --- docs/configuration.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/configuration.md b/docs/configuration.md index 7221ef8..e43a8b8 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -188,6 +188,7 @@ The `/assets/manifest.json` can also be edited to change the app (pwa) name, des - [Dracula theme](https://draculatheme.com/homer) by [@Tuetenk0pp](https://github.com/Tuetenk0pp) - [Homer Theme v2](https://github.com/walkxcode/homer-theme) by [walkxcode](https://github.com/walkxcode) +- [Catppuccin theme](https://github.com/mrpbennett/catppucin-homer) by [@mrpbenett](https://github.com/mrpbennett) ## PWA Icons From 4c9212c93ecc47f83c0190f43808f9ff1bc19e6b Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Fri, 28 Oct 2022 10:24:38 +0200 Subject: [PATCH 071/435] Update README.md --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 529ceff..95faada 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,9 @@

A dead simple static HOMepage for your servER to keep your services on hand, from a simple yaml configuration file.

- +

+ Buy Me A Coffee +

Demo From 7172b6f507e0161a685c34e573e0ef838c974846 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sat, 29 Oct 2022 15:39:35 +0200 Subject: [PATCH 072/435] Update dependencies --- package.json | 20 +- src/App.vue | 6 +- yarn.lock | 800 +++++++++++++++++++++++++-------------------------- 3 files changed, 398 insertions(+), 428 deletions(-) diff --git a/package.json b/package.json index 911cb56..93953c1 100644 --- a/package.json +++ b/package.json @@ -8,22 +8,22 @@ "lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs --fix --ignore-path .gitignore" }, "dependencies": { - "@fortawesome/fontawesome-free": "^6.1.2", + "@fortawesome/fontawesome-free": "^6.2.0", "bulma": "^0.9.4", - "js-yaml": "^4.1.0", + "yaml": "^2.1.3", "lodash.merge": "^4.6.2", - "vue": "^3.2.37" + "vue": "^3.2.41" }, "devDependencies": { - "@rushstack/eslint-patch": "^1.1.4", - "@vitejs/plugin-vue": "^3.0.3", + "@rushstack/eslint-patch": "^1.2.0", + "@vitejs/plugin-vue": "^3.2.0", "@vue/eslint-config-prettier": "^7.0.0", - "eslint": "^8.22.0", - "eslint-plugin-vue": "^9.3.0", + "eslint": "^8.26.0", + "eslint-plugin-vue": "^9.6.0", "prettier": "^2.7.1", - "sass": "^1.54.4", - "vite": "^3.0.7", - "vite-plugin-pwa": "^0.12.3" + "sass": "^1.55.0", + "vite": "^3.2.1", + "vite-plugin-pwa": "^0.13.1" }, "license": "Apache-2.0" } diff --git a/src/App.vue b/src/App.vue index f2089ee..25e943f 100644 --- a/src/App.vue +++ b/src/App.vue @@ -141,7 +141,7 @@ @@ -133,4 +155,9 @@ export default { } } } + +//Location Time +.location-time { + margin-left: 20px; +} From 5bb84dcefbafab8d80313771854c1d982560ee1a Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 30 Oct 2022 14:48:45 +0100 Subject: [PATCH 076/435] Fix openweather service --- dummy-data/openweather/weather | 46 +++++++++++++++++++++++++ public/assets/config-demo.yml.dist | 6 ++++ src/components/services/OpenWeather.vue | 16 +++++---- src/components/services/Ping.vue | 7 ++-- 4 files changed, 66 insertions(+), 9 deletions(-) create mode 100644 dummy-data/openweather/weather diff --git a/dummy-data/openweather/weather b/dummy-data/openweather/weather new file mode 100644 index 0000000..80245ef --- /dev/null +++ b/dummy-data/openweather/weather @@ -0,0 +1,46 @@ +{ + "coord": { + "lon": 4.5833, + "lat": 45.75 + }, + "weather": [ + { + "id": 804, + "main": "Clouds", + "description": "overcast clouds", + "icon": "04d" + } + ], + "base": "stations", + "main": { + "temp": 23, + "feels_like": 22.3, + "temp_min": 21.75, + "temp_max": 25.03, + "pressure": 1019, + "humidity": 36, + "sea_level": 1019, + "grnd_level": 957 + }, + "visibility": 10000, + "wind": { + "speed": 2.29, + "deg": 174, + "gust": 6.22 + }, + "clouds": { + "all": 97 + }, + "dt": 1667136939, + "sys": { + "type": 2, + "id": 2005747, + "country": "FR", + "sunrise": 1667110705, + "sunset": 1667147524 + }, + "timezone": 3600, + "id": 2996943, + "name": "Arrondissement de Lyon", + "cod": 200 + } \ No newline at end of file diff --git a/public/assets/config-demo.yml.dist b/public/assets/config-demo.yml.dist index 43188fb..4d088cc 100644 --- a/public/assets/config-demo.yml.dist +++ b/public/assets/config-demo.yml.dist @@ -100,6 +100,12 @@ services: keywords: "demo" url: "#" target: "_blank" + - name: "Weather" + location: "Lyon" + apikey: "xxxxxxxxxxxx" # insert your own API key here. Request one from https://openweathermap.org/api. + units: "metric" + endpoint: "https://homer-demo-content.netlify.app/openweather/weather" + type: "OpenWeather" - name: "interesting links" icon: "fas fa-solid fa-arrow-up-right-from-square" items: diff --git a/src/components/services/OpenWeather.vue b/src/components/services/OpenWeather.vue index 3169866..649e8e5 100644 --- a/src/components/services/OpenWeather.vue +++ b/src/components/services/OpenWeather.vue @@ -23,7 +23,7 @@

{{ name }}

- {{ temp | tempSuffix(this.item.units) }} + {{ temperature }} {{ locationTime }} @@ -68,15 +68,13 @@ export default { } return `${this.temp} ${unit}`; }, - }, - created() { - this.fetchWeather(); - }, - computed: { locationTime: function () { return this.calcTime(this.timezoneOffset); }, }, + created() { + this.fetchWeather(); + }, methods: { fetchWeather: async function () { let locationQuery; @@ -89,7 +87,11 @@ export default { } const apiKey = this.item.apikey || this.item.apiKey; - const url = `https://api.openweathermap.org/data/2.5/weather?${locationQuery}&appid=${apiKey}&units=${this.item.units}`; + + let url = `https://api.openweathermap.org/data/2.5/weather?${locationQuery}&appid=${apiKey}&units=${this.item.units}`; + if (this.item.endpoint) { + url = this.item.endpoint; + } fetch(url) .then((response) => { if (!response.ok) { diff --git a/src/components/services/Ping.vue b/src/components/services/Ping.vue index 07bc053..e2db050 100644 --- a/src/components/services/Ping.vue +++ b/src/components/services/Ping.vue @@ -29,9 +29,12 @@ export default { }, methods: { fetchStatus: async function () { - const method = typeof this.item.method === 'string' ? this.item.method.toUpperCase() : 'HEAD'; + const method = + typeof this.item.method === "string" + ? this.item.method.toUpperCase() + : "HEAD"; - if (!['GET', 'HEAD', 'OPTION'].includes(method)) { + if (!["GET", "HEAD", "OPTION"].includes(method)) { console.error(`Ping: ${method} is not a supported HTTP method`); return; } From ac5f04f058344be4eb61bcc8684771973f18bc71 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 30 Oct 2022 15:13:59 +0100 Subject: [PATCH 077/435] Shorter weather title --- dummy-data/openweather/weather | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dummy-data/openweather/weather b/dummy-data/openweather/weather index 80245ef..2497313 100644 --- a/dummy-data/openweather/weather +++ b/dummy-data/openweather/weather @@ -41,6 +41,6 @@ }, "timezone": 3600, "id": 2996943, - "name": "Arrondissement de Lyon", + "name": "Lyon", "cod": 200 } \ No newline at end of file From cfd31b86b5a71d059dd9b6f24f0df5b20ac9c0ca Mon Sep 17 00:00:00 2001 From: Shagon94 Date: Sun, 30 Oct 2022 18:32:51 +0100 Subject: [PATCH 078/435] qBittorrent service (#540) qBittorrent service --- docs/customservices.md | 56 ++++++--- dummy-data/README.md | 13 ++- dummy-data/qBittorrent/api/v2/torrents/info | 53 +++++++++ dummy-data/qBittorrent/api/v2/transfer/info | 10 ++ src/components/services/qBittorrent.vue | 120 ++++++++++++++++++++ 5 files changed, 229 insertions(+), 23 deletions(-) create mode 100644 dummy-data/qBittorrent/api/v2/torrents/info create mode 100644 dummy-data/qBittorrent/api/v2/transfer/info create mode 100644 src/components/services/qBittorrent.vue diff --git a/docs/customservices.md b/docs/customservices.md index 3c4f5ad..e84afdb 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -7,25 +7,28 @@ if your homer instance is secured behind some form of authentication or access r Available services are in `src/components/`. Here is an overview of all custom services that are available within Homer: -+ [PiHole](#pihole) -+ [OpenWeatherMap](#openweathermap) -+ [Medusa](#medusa) -+ [Lidarr, Prowlarr, Sonarr and Radarr](#lidarr-prowlarr-sonarr-and-radarr) -+ [PaperlessNG](#paperlessng) -+ [Ping](#ping) -+ [Prometheus](#prometheus) -+ [AdGuard Home](#adguard-home) -+ [Portainer](#portainer) -+ [Emby / Jellyfin](#emby--jellyfin) -+ [Uptime Kuma](#uptime-kuma) -+ [Tautulli](#tautulli) -+ [Mealie](#mealie) -+ [Healthchecks](#healthchecks) -+ [Proxmox](#proxmox) + +- [Custom Services](#custom-services) + - [Common options](#common-options) + - [PiHole](#pihole) + - [OpenWeatherMap](#openweathermap) + - [Medusa](#medusa) + - [Lidarr, Prowlarr, Sonarr and Radarr](#lidarr-prowlarr-sonarr-and-radarr) + - [PaperlessNG](#paperlessng) + - [Ping](#ping) + - [Prometheus](#prometheus) + - [AdGuard Home](#adguard-home) + - [Portainer](#portainer) + - [Emby / Jellyfin](#emby--jellyfin) + - [Uptime Kuma](#uptime-kuma) + - [Tautulli](#tautulli) + - [Mealie](#mealie) + - [Healthchecks](#healthchecks) + - [Proxmox](#proxmox) + - [qBittorrent](#qbittorrent) If you experiencing any issue, please have a look to the [troubleshooting](troubleshooting.md) page. - ## Common options ```yaml @@ -272,4 +275,23 @@ Configuration example: warning_value: 50 danger_value: 80 api_token: "PVEAPIToken=root@pam!your-api-token-name=your-api-token-key" -``` \ No newline at end of file +``` + +## qBittorrent + +This service displays the global upload and download rates, as well as the number of torrents +listed. The service communicates with the qBittorrent API interface which needs +to be accessible from the browser. Please consult +[the instructions](https://github.com/qbittorrent/qBittorrent/pull/12579) +for setting up qBittorrent and make sure the correct CORS-settings are applied. Examples for various +servers can be found at [enable-cors.org](https://enable-cors.org/server.html). + +```yaml +- name: "qBittorrent" + logo: "assets/tools/sample.png" + url: "http://192.168.1.2:8080" # Your rTorrent web UI, f.e. ruTorrent or Flood. + type: "qBittorrent" + rateInterval: 2000 # Interval for updating the download and upload rates. + torrentInterval: 5000 # Interval for updating the torrent count. + target: "_blank" # optional html a tag target attribute +``` diff --git a/dummy-data/README.md b/dummy-data/README.md index eeff4ec..6db4712 100644 --- a/dummy-data/README.md +++ b/dummy-data/README.md @@ -1,15 +1,16 @@ # Dummy data -This directory content makes possible to test custom services cards or create a demo without actually running the service. +This directory content makes possible to test custom services cards or create a demo without actually running the service. The principle is simple: save a sample output of the API used in the service in a static file in this directory. The path must be identical as the service endpoint to be used seamlessly. -## How to add a new services sample: +## How to add a new services sample -- create a directory for your service, and any sub-folder existing in the service api path. +- create a directory for your service, and any sub-folder existing in the service api path. - save the api output in a file named after the service endpoint. Example: -``` + +```sh mkdir pihole -curl http://my-pihole.me/admin/api.php -o pihole/api.php # /admin is omited because for PiHole, the implementation expect it to be in the base url (`url` or `enpoint` property) -``` \ No newline at end of file +curl http://my-pihole.me/admin/api.php -o pihole/api.php # /admin is omited because for PiHole, the implementation expect it to be in the base url (`url` or `endpoint` property) +``` diff --git a/dummy-data/qBittorrent/api/v2/torrents/info b/dummy-data/qBittorrent/api/v2/torrents/info new file mode 100644 index 0000000..e1bc722 --- /dev/null +++ b/dummy-data/qBittorrent/api/v2/torrents/info @@ -0,0 +1,53 @@ +[ + { + "added_on": 1666985518, + "amount_left": 0, + "auto_tmm": false, + "availability": -1, + "category": "", + "completed": 1474873344, + "completion_on": 1666985584, + "content_path": "/downloads/ubuntu-22.04.1-live-server-amd64.iso", + "dl_limit": -1, + "dlspeed": 0, + "download_path": "", + "downloaded": 1513976240, + "downloaded_session": 0, + "eta": 8640000, + "f_l_piece_prio": false, + "force_start": false, + "hash": "cf3ea75e2ebbd30e0da6e6e215e2226bf35f2e33", + "infohash_v1": "cf3ea75e2ebbd30e0da6e6e215e2226bf35f2e33", + "infohash_v2": "", + "last_activity": 1666985588, + "magnet_uri": "magnet:?xt=urn:btih:cf3ea75e2ebbd30e0da6e6e215e2226bf35f2e33&dn=ubuntu-22.04.1-live-server-amd64.iso&tr=https%3a%2f%2ftorrent.ubuntu.com%2fannounce&tr=https%3a%2f%2fipv6.torrent.ubuntu.com%2fannounce", + "max_ratio": 0, + "max_seeding_time": -1, + "name": "ubuntu-22.04.1-live-server-amd64.iso", + "num_complete": 0, + "num_incomplete": 583, + "num_leechs": 0, + "num_seeds": 0, + "priority": 0, + "progress": 1, + "ratio": 1.7163413343924075e-05, + "ratio_limit": -2, + "save_path": "/downloads/", + "seeding_time": 4, + "seeding_time_limit": -2, + "seen_complete": 1666985584, + "seq_dl": false, + "size": 1474873344, + "state": "pausedUP", + "super_seeding": false, + "tags": "", + "time_active": 69, + "total_size": 1474873344, + "tracker": "", + "trackers_count": 2, + "up_limit": -1, + "uploaded": 25985, + "uploaded_session": 0, + "upspeed": 0 + } +] \ No newline at end of file diff --git a/dummy-data/qBittorrent/api/v2/transfer/info b/dummy-data/qBittorrent/api/v2/transfer/info new file mode 100644 index 0000000..dd7b318 --- /dev/null +++ b/dummy-data/qBittorrent/api/v2/transfer/info @@ -0,0 +1,10 @@ +{ + "connection_status": "connected", + "dht_nodes": 318, + "dl_info_data": 23481469329, + "dl_info_speed": 1234567, + "dl_rate_limit": 40960000, + "up_info_data": 1788370216, + "up_info_speed": 765432, + "up_rate_limit": 10547200 +} \ No newline at end of file diff --git a/src/components/services/qBittorrent.vue b/src/components/services/qBittorrent.vue new file mode 100644 index 0000000..1f1ef49 --- /dev/null +++ b/src/components/services/qBittorrent.vue @@ -0,0 +1,120 @@ + + + + + \ No newline at end of file From 7edcfe0705ea2b4349da2e2bde581a8be872cd6f Mon Sep 17 00:00:00 2001 From: tralce Date: Sun, 30 Oct 2022 13:35:56 -0400 Subject: [PATCH 079/435] Fixed the table in the Proxmox section (#534) Co-authored-by: Bastien Wirtz --- docs/customservices.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/customservices.md b/docs/customservices.md index e84afdb..3f17abc 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -256,7 +256,7 @@ This service displays status information of a Proxmox node (VMs running and disk The API Token (or the user asigned to that token if not separated permissions is checked) are this: | Path | Permission | Comments | -| ------------------ | ---------- | | +|--------------------|------------|-------------------------------------------------------------------| | /nodes/ | Sys.Audit | | | /vms/ | VM.Audit | You need to have this permission on any VM you want to be counted | From 51ba5ff503605194516b81e322e98263f60e58b2 Mon Sep 17 00:00:00 2001 From: lindely Date: Mon, 31 Oct 2022 10:09:59 +0100 Subject: [PATCH 080/435] Service for rTorrent. (#511) Service for rTorrent. --- docs/customservices.md | 22 ++++ dummy-data/rtorrent/download_list | 10 ++ dummy-data/rtorrent/global_down | 6 ++ dummy-data/rtorrent/global_up | 6 ++ src/components/services/Rtorrent.vue | 153 +++++++++++++++++++++++++++ 5 files changed, 197 insertions(+) create mode 100644 dummy-data/rtorrent/download_list create mode 100644 dummy-data/rtorrent/global_down create mode 100644 dummy-data/rtorrent/global_up create mode 100644 src/components/services/Rtorrent.vue diff --git a/docs/customservices.md b/docs/customservices.md index 3f17abc..fb3f2a7 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -25,6 +25,7 @@ within Homer: - [Mealie](#mealie) - [Healthchecks](#healthchecks) - [Proxmox](#proxmox) + - [rTorrent](#rtorrent) - [qBittorrent](#qbittorrent) If you experiencing any issue, please have a look to the [troubleshooting](troubleshooting.md) page. @@ -249,6 +250,27 @@ Two lines are needed in the config.yml : The url must be the root url of the Healthchecks application. The Healthchecks API key can be found in Settings > API Access > API key (read-only). The key is needed to access Healthchecks API. +## rTorrent + +This service displays the global upload and download rates, as well as the number of torrents +listed in rTorrent. The service communicates with the rTorrent XML-RPC interface which needs +to be accessible from the browser. Please consult +[the instructions](https://github.com/rakshasa/rtorrent-doc/blob/master/RPC-Setup-XMLRPC.md) +for setting up rTorrent and make sure the correct CORS-settings are applied. Examples for various +servers can be found at https://enable-cors.org/server.html. + +```yaml +- name: "rTorrent" + logo: "assets/tools/sample.png" + url: "http://192.168.0.151" # Your rTorrent web UI, f.e. ruTorrent or Flood. + xmlrpc: "http://192.168.0.151:8081" # Reverse proxy for rTorrent's XML-RPC. + type: "Rtorrent" + rateInterval: 5000 # Interval for updating the download and upload rates. + torrentInterval: 60000 # Interval for updating the torrent count. + username: "username" # Username for logging into rTorrent (if applicable). + password: "password" # Password for logging into rTorrent (if applicable). + + ## Proxmox This service displays status information of a Proxmox node (VMs running and disk, memory and cpu used). It uses the proxmox API and [API Tokens](https://pve.proxmox.com/pve-docs/pveum-plain.html) for authorization so you need to generate one to set in the yaml config. You can set it up in Proxmox under Permissions > API Tokens. You also need to know the realm the user of the API Token is assigned to (by default pam). diff --git a/dummy-data/rtorrent/download_list b/dummy-data/rtorrent/download_list new file mode 100644 index 0000000..1d08e51 --- /dev/null +++ b/dummy-data/rtorrent/download_list @@ -0,0 +1,10 @@ + + + + +2BAC78C9E10D82415142E57D24601F2FD8927816 +8BB10DB9EA239106D4907601C342ABBA29BE4391 +2790CE71493BE7083929D5A1CE9CFD6B8394F224 + + + \ No newline at end of file diff --git a/dummy-data/rtorrent/global_down b/dummy-data/rtorrent/global_down new file mode 100644 index 0000000..d48e884 --- /dev/null +++ b/dummy-data/rtorrent/global_down @@ -0,0 +1,6 @@ + + + +149279 + + \ No newline at end of file diff --git a/dummy-data/rtorrent/global_up b/dummy-data/rtorrent/global_up new file mode 100644 index 0000000..93a009c --- /dev/null +++ b/dummy-data/rtorrent/global_up @@ -0,0 +1,6 @@ + + + +45616 + + \ No newline at end of file diff --git a/src/components/services/Rtorrent.vue b/src/components/services/Rtorrent.vue new file mode 100644 index 0000000..75efb7b --- /dev/null +++ b/src/components/services/Rtorrent.vue @@ -0,0 +1,153 @@ + + + + + \ No newline at end of file From bdad8933ff354ed33a4f3c004cf63433309e9597 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Mon, 31 Oct 2022 10:12:15 +0100 Subject: [PATCH 081/435] Apply lint fixes --- src/components/services/Rtorrent.vue | 115 ++++++----- src/components/services/qBittorrent.vue | 242 ++++++++++++------------ 2 files changed, 185 insertions(+), 172 deletions(-) diff --git a/src/components/services/Rtorrent.vue b/src/components/services/Rtorrent.vue index 75efb7b..ed8e7a6 100644 --- a/src/components/services/Rtorrent.vue +++ b/src/components/services/Rtorrent.vue @@ -8,14 +8,13 @@ {{ downRate }} - - {{ upRate }} - + {{ upRate }}

\ No newline at end of file + diff --git a/src/components/services/qBittorrent.vue b/src/components/services/qBittorrent.vue index 1f1ef49..06dd47c 100644 --- a/src/components/services/qBittorrent.vue +++ b/src/components/services/qBittorrent.vue @@ -1,120 +1,122 @@ - - - - - \ No newline at end of file + + + + + From f72c0bc7811dc19499418371e08930747fe087dc Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sat, 5 Nov 2022 15:11:48 +0100 Subject: [PATCH 082/435] New Copy to clipboard custom service --- docs/customservices.md | 18 +++++ src/components/services/CopyToClipboard.vue | 85 +++++++++++++++++++++ 2 files changed, 103 insertions(+) create mode 100644 src/components/services/CopyToClipboard.vue diff --git a/docs/customservices.md b/docs/customservices.md index fb3f2a7..65f3d4c 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -27,6 +27,7 @@ within Homer: - [Proxmox](#proxmox) - [rTorrent](#rtorrent) - [qBittorrent](#qbittorrent) + - [CopyToClipboard](#copy-to-clipboard) If you experiencing any issue, please have a look to the [troubleshooting](troubleshooting.md) page. @@ -317,3 +318,20 @@ servers can be found at [enable-cors.org](https://enable-cors.org/server.html). torrentInterval: 5000 # Interval for updating the torrent count. target: "_blank" # optional html a tag target attribute ``` + +## Copy to Clipboard + +This service displays the same information of a generic one, but shows an icon button on the indicator place (right side) you can click to get the content of the `clipboard` field copied to your clipboard. + +You can still provide an `url` that would be open when clicked anywhere but on the icon button. + +Configuration example: + +```yaml +- name: "Copy me!" + logo: "assets/tools/sample.png" + subtitle: "Subtitle text goes here" + url: "#" + type: "CopyToClipboard" + clipboard: "this text will be copied to your clipboard" +``` diff --git a/src/components/services/CopyToClipboard.vue b/src/components/services/CopyToClipboard.vue new file mode 100644 index 0000000..18c4dc3 --- /dev/null +++ b/src/components/services/CopyToClipboard.vue @@ -0,0 +1,85 @@ + + + + + From d32f7f6467c1456b32ea4675d17bfba1c428c2b7 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sat, 5 Nov 2022 15:21:18 +0100 Subject: [PATCH 083/435] Proxmox improvements --- docs/customservices.md | 5 +++ src/components/services/Proxmox.vue | 53 +++++++++++++++++++++-------- 2 files changed, 44 insertions(+), 14 deletions(-) diff --git a/docs/customservices.md b/docs/customservices.md index 65f3d4c..2e74443 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -298,6 +298,11 @@ Configuration example: warning_value: 50 danger_value: 80 api_token: "PVEAPIToken=root@pam!your-api-token-name=your-api-token-key" + # values below this line are optional (default value are false/empty): + hide_decimals: true # removes decimals from stats values. + hide: ["vms", "vms_total", "lxcs", "lxcs_total", "disk", "mem", "cpu"] # hides values included in the array + small_font_on_small_screens: true # uses small font on small screens (like mobile) + small_font_on_desktop: true # uses small font on desktops (just in case you're showing much info) ``` ## qBittorrent diff --git a/src/components/services/Proxmox.vue b/src/components/services/Proxmox.vue index 1d2c2c9..2b533db 100644 --- a/src/components/services/Proxmox.vue +++ b/src/components/services/Proxmox.vue @@ -13,11 +13,12 @@
Error loading info
-
- VMs: {{ vms.running }}/{{vms.total}} - Disk: {{ diskUsed }}% - Mem: {{ memoryUsed }}% - CPU: {{ cpuUsed }}% +
+ VMs: {{ vms.running }}/{{vms.total}} + LXCs: {{ lxcs.running }}/{{lxcs.total}} + Disk: {{ diskUsed }}% + Mem: {{ memoryUsed }}% + CPU: {{ cpuUsed }}%

@@ -47,13 +48,19 @@ total: 0, running: 0 }, + lxcs: { + total: 0, + running: 0 + }, memoryUsed: 0, diskUsed: 0, cpuUsed: 0, + hide: [], error: false, loading: true }), created() { + if (this.item.hide) this.hide = this.item.hide; this.fetchStatus(); }, methods: { @@ -71,13 +78,20 @@ } const status = await this.fetch(`/api2/json/nodes/${this.item.node}/status`, options); // main metrics: - this.memoryUsed = ( (status.data.memory.used * 100) / status.data.memory.total ).toFixed(1); - this.diskUsed = ( (status.data.rootfs.used * 100) / status.data.rootfs.total ).toFixed(1); - this.cpuUsed = (status.data.cpu * 100).toFixed(1); + const decimalsToShow = this.item.hide_decimals ? 0 : 1; + this.memoryUsed = ( (status.data.memory.used * 100) / status.data.memory.total ).toFixed(decimalsToShow); + this.diskUsed = ( (status.data.rootfs.used * 100) / status.data.rootfs.total ).toFixed(decimalsToShow); + this.cpuUsed = (status.data.cpu * 100).toFixed(decimalsToShow); // vms: - const vms = await this.fetch(`/api2/json/nodes/${this.item.node}/qemu`, options); - this.vms.total += vms.data.length; - this.vms.running += vms.data.filter( i => i.status === 'running' ).length; + if (this.isValueShown('vms')) { + const vms = await this.fetch(`/api2/json/nodes/${this.item.node}/qemu`, options); + this.parseVMsAndLXCs(vms, this.vms); + } + // lxc containers: + if (this.isValueShown('lxcs')) { + const lxcs = await this.fetch(`/api2/json/nodes/${this.item.node}/lxc`, options); + this.parseVMsAndLXCs(lxcs, this.lxcs); + } this.error = false; } catch(err) { console.log(err); @@ -85,6 +99,15 @@ } this.loading = false; }, + parseVMsAndLXCs(items, value) { + value.total += items.data.length; + value.running += items.data.filter( i => i.status === 'running' ).length; + // if no vms, hide this value: + if (value.total == 0) this.hide.push('lxcs'); + }, + isValueShown(value) { + return this.hide.indexOf(value) == -1; + } }, }; @@ -102,9 +125,11 @@ .danger { color: red } - .metrics { - display: flex; - justify-content: space-between; + .metrics .margined:not(:first-child) { + margin-left: 0.3rem; + } + .is-small { + font-size: small; } \ No newline at end of file From 24b6dedbe188aec151a09414f7439fa28cc811f9 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sat, 5 Nov 2022 15:24:41 +0100 Subject: [PATCH 084/435] Apply lint --- src/components/services/Proxmox.vue | 314 ++++++++++++++++------------ 1 file changed, 186 insertions(+), 128 deletions(-) diff --git a/src/components/services/Proxmox.vue b/src/components/services/Proxmox.vue index 2b533db..8136050 100644 --- a/src/components/services/Proxmox.vue +++ b/src/components/services/Proxmox.vue @@ -1,135 +1,193 @@ - - - - - \ No newline at end of file + parseVMsAndLXCs(items, value) { + value.total += items.data.length; + value.running += items.data.filter((i) => i.status === "running").length; + // if no vms, hide this value: + if (value.total == 0) this.hide.push("lxcs"); + }, + isValueShown(value) { + return this.hide.indexOf(value) == -1; + }, + }, +}; + + + From b5048fc353db26186563bb2b1319941b5c11a54a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bernhard=20Gro=C3=9Fer?= <30469627+boerniee@users.noreply.github.com> Date: Sat, 5 Nov 2022 15:32:56 +0100 Subject: [PATCH 085/435] Speedtesttracker integration (#262) added SpeedtestTracker service --- docs/customservices.md | 4 + src/components/services/SpeedtestTracker.vue | 86 ++++++++++++++++++++ 2 files changed, 90 insertions(+) create mode 100644 src/components/services/SpeedtestTracker.vue diff --git a/docs/customservices.md b/docs/customservices.md index 2e74443..b81094e 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -340,3 +340,7 @@ Configuration example: type: "CopyToClipboard" clipboard: "this text will be copied to your clipboard" ``` + +## SpeedtestTracker + +For the SpeedtestTracker service you just need to define a entry with type `SpeedtestTracker`. diff --git a/src/components/services/SpeedtestTracker.vue b/src/components/services/SpeedtestTracker.vue new file mode 100644 index 0000000..f836001 --- /dev/null +++ b/src/components/services/SpeedtestTracker.vue @@ -0,0 +1,86 @@ + + + + + From beb5755747316be8b1d9579d0e194d5a35714f3d Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sat, 5 Nov 2022 22:14:32 +0100 Subject: [PATCH 086/435] Rework speedtesttracker based on the Generic component --- src/components/services/SpeedtestTracker.vue | 91 +++++++------------- 1 file changed, 32 insertions(+), 59 deletions(-) diff --git a/src/components/services/SpeedtestTracker.vue b/src/components/services/SpeedtestTracker.vue index f836001..d4ebd74 100644 --- a/src/components/services/SpeedtestTracker.vue +++ b/src/components/services/SpeedtestTracker.vue @@ -1,61 +1,43 @@ - - From d141a69a7debea39aa17bff52cef3b8ce5e63f45 Mon Sep 17 00:00:00 2001 From: bchavez Date: Sun, 23 Oct 2022 21:52:30 -0600 Subject: [PATCH 087/435] ConnectivityChecker: Bug Fix - Remove double // in aliveCheckUrl causing Invalid Redirect URL with CloudFlare Access. --- src/components/ConnectivityChecker.vue | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/components/ConnectivityChecker.vue b/src/components/ConnectivityChecker.vue index 0e724fc..5c77618 100644 --- a/src/components/ConnectivityChecker.vue +++ b/src/components/ConnectivityChecker.vue @@ -56,9 +56,8 @@ export default { // extra check to make sure we're not offline let that = this; - const aliveCheckUrl = `${window.location.origin}${ - window.location.pathname - }/index.html?t=${new Date().valueOf()}`; + const urlPath = window.location.pathname.replace(/\/+$/, ""); + const aliveCheckUrl = `${window.location.origin}${urlPath}/index.html?t=${new Date().valueOf()}`; return fetch(aliveCheckUrl, { method: "HEAD", cache: "no-store", From c9a649518616f3cf4e8c39d772dfbc2eff330a03 Mon Sep 17 00:00:00 2001 From: Julien Roy Date: Sat, 5 Nov 2022 22:44:25 +0100 Subject: [PATCH 088/435] What's up docker custom service (#444) Add WUD --- docs/customservices.md | 16 ++++++ src/components/services/WUD.vue | 92 +++++++++++++++++++++++++++++++++ 2 files changed, 108 insertions(+) create mode 100644 src/components/services/WUD.vue diff --git a/docs/customservices.md b/docs/customservices.md index b81094e..a2d5f02 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -28,6 +28,8 @@ within Homer: - [rTorrent](#rtorrent) - [qBittorrent](#qbittorrent) - [CopyToClipboard](#copy-to-clipboard) + - [Speedtest Tracker](#SpeedtestTracker) + - [What's Up Docker](#whats-up-docker) If you experiencing any issue, please have a look to the [troubleshooting](troubleshooting.md) page. @@ -344,3 +346,17 @@ Configuration example: ## SpeedtestTracker For the SpeedtestTracker service you just need to define a entry with type `SpeedtestTracker`. + +## What's up Docker + +What's up Docker allow to display info about the number of container running and the number for which an update is available on your Homer dashboard. + +The following configuration is available for the WUD service. + +```yaml +- name: "What's Up Docker" + logo: "assets/tools/sample.png" + subtitle: "Docker image update notifier" + url: "http://192.168.1.12:3001" + type: "WUD" +``` \ No newline at end of file diff --git a/src/components/services/WUD.vue b/src/components/services/WUD.vue new file mode 100644 index 0000000..917f3bd --- /dev/null +++ b/src/components/services/WUD.vue @@ -0,0 +1,92 @@ + + + + + From 6868a0911b928b628357d6b0ad2e6c5850843ca6 Mon Sep 17 00:00:00 2001 From: Sean McGrath Date: Mon, 7 Nov 2022 22:18:59 +1300 Subject: [PATCH 089/435] Add scope and start_url to PWA manifest These URLs are relative, so given that manifest.json lives in assets/, these should point to the root of the site --- vite.config.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/vite.config.js b/vite.config.js index f08041d..15ff457 100644 --- a/vite.config.js +++ b/vite.config.js @@ -21,6 +21,8 @@ export default defineConfig({ short_name: "Homer", description: "Home Server Dashboard", theme_color: "#3367D6", + start_url: "../", + scope: "../", icons: [ { src: "./icons/pwa-192x192.png", From a8292ef7579f11b4dfa4724d53bdaa4799b87220 Mon Sep 17 00:00:00 2001 From: csleal <80231530+csleal@users.noreply.github.com> Date: Mon, 14 Nov 2022 19:52:33 -0300 Subject: [PATCH 090/435] Update customservices.md --- docs/customservices.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/customservices.md b/docs/customservices.md index a2d5f02..7448a8c 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -272,6 +272,7 @@ servers can be found at https://enable-cors.org/server.html. torrentInterval: 60000 # Interval for updating the torrent count. username: "username" # Username for logging into rTorrent (if applicable). password: "password" # Password for logging into rTorrent (if applicable). +``` ## Proxmox @@ -359,4 +360,4 @@ The following configuration is available for the WUD service. subtitle: "Docker image update notifier" url: "http://192.168.1.12:3001" type: "WUD" -``` \ No newline at end of file +``` From f62972f65932a486ec0355cd61df3372fca371f3 Mon Sep 17 00:00:00 2001 From: Maxime Mouchet Date: Fri, 18 Nov 2022 20:29:12 +0100 Subject: [PATCH 091/435] Properly pass signals to lighttpd --- entrypoint.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/entrypoint.sh b/entrypoint.sh index 48df1e6..e970d34 100644 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -15,4 +15,4 @@ if [[ "${INIT_ASSETS}" == "1" ]] && [[ ! -f "/www/assets/config.yml" ]]; then fi echo "Starting webserver" -lighttpd -D -f /lighttpd.conf +exec lighttpd -D -f /lighttpd.conf From 98fe0a393970070fa04b5f37dbbb7a4c3ef82beb Mon Sep 17 00:00:00 2001 From: Matt Bentley Date: Sat, 19 Nov 2022 10:14:22 -0500 Subject: [PATCH 092/435] Adds SABnzbd custom service; fixes #494 (#555) * Adds SABnzbd custom service; fixes #494 --- docs/customservices.md | 16 +++++ src/components/services/SABnzbd.vue | 99 +++++++++++++++++++++++++++++ 2 files changed, 115 insertions(+) create mode 100644 src/components/services/SABnzbd.vue diff --git a/docs/customservices.md b/docs/customservices.md index 7448a8c..5bb08ff 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -30,6 +30,7 @@ within Homer: - [CopyToClipboard](#copy-to-clipboard) - [Speedtest Tracker](#SpeedtestTracker) - [What's Up Docker](#whats-up-docker) + - [SABnzbd](#sabnzbd) If you experiencing any issue, please have a look to the [troubleshooting](troubleshooting.md) page. @@ -361,3 +362,18 @@ The following configuration is available for the WUD service. url: "http://192.168.1.12:3001" type: "WUD" ``` + +## SABnzbd + +The SABnzbd service can allow you to show the number of currently active +downloads on your SABnzbd instance. An API key is required, and can be obtained from +the "Config" > "General" section of the SABnzbd config in the SABnzbd web UI. + +```yaml +- name: "SABnzbd" + logo: "assets/tools/sample.png" + url: "http://192.168.0.151:8080" + type: "SABnzbd" + apikey: "MY-SUPER-SECRET-API-KEY" + downloadInterval: 5000 # (Optional) Interval (in ms) for updating the download count +``` diff --git a/src/components/services/SABnzbd.vue b/src/components/services/SABnzbd.vue new file mode 100644 index 0000000..2f93c71 --- /dev/null +++ b/src/components/services/SABnzbd.vue @@ -0,0 +1,99 @@ + + + + + From 70f583c3e1d7c4bc1cca6b9c1cec6ca2e1f9e7b3 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Sun, 27 Nov 2022 18:41:12 +0100 Subject: [PATCH 093/435] Octoprint service (#324) (#560) Add Octoprint service. --- docs/customservices.md | 32 +++- dummy-data/README.md | 6 + dummy-data/octoprint/api/job | 30 +++ .../api/status_printer_offline-error.json | 26 +++ .../octoprint/api/status_printer_offline.json | 26 +++ .../api/status_printer_operational.json | 26 +++ .../api/status_printer_printing.json | 30 +++ .../api/status_printer_printing_1of2.json | 30 +++ .../api/status_printer_printing_2of2.json | 30 +++ .../api/status_printing_completion.json | 30 +++ .../speedtesttracker/api/speedtest/latest | 7 + package.json | 6 +- public/assets/config-demo.yml.dist | 5 + src/assets/app.scss | 2 +- src/assets/components/status.scss | 48 +++++ src/components/services/OctoPrint.vue | 108 +++++++++++ yarn.lock | 172 +++++++++++++++++- 17 files changed, 596 insertions(+), 18 deletions(-) create mode 100644 dummy-data/octoprint/api/job create mode 100644 dummy-data/octoprint/api/status_printer_offline-error.json create mode 100644 dummy-data/octoprint/api/status_printer_offline.json create mode 100644 dummy-data/octoprint/api/status_printer_operational.json create mode 100644 dummy-data/octoprint/api/status_printer_printing.json create mode 100644 dummy-data/octoprint/api/status_printer_printing_1of2.json create mode 100644 dummy-data/octoprint/api/status_printer_printing_2of2.json create mode 100644 dummy-data/octoprint/api/status_printing_completion.json create mode 100644 dummy-data/speedtesttracker/api/speedtest/latest create mode 100644 src/assets/components/status.scss create mode 100644 src/components/services/OctoPrint.vue diff --git a/docs/customservices.md b/docs/customservices.md index 5bb08ff..88e4e2f 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -31,6 +31,7 @@ within Homer: - [Speedtest Tracker](#SpeedtestTracker) - [What's Up Docker](#whats-up-docker) - [SABnzbd](#sabnzbd) + - [OctoPrint](#sabnzbd) If you experiencing any issue, please have a look to the [troubleshooting](troubleshooting.md) page. @@ -84,7 +85,7 @@ Two lines are needed in the config.yml : ```yaml type: "Medusa" - apikey: "01234deb70424befb1f4ef6a23456789" + apikey: "<---insert-api-key-here--->" ``` The url must be the root url of Medusa application. @@ -97,7 +98,7 @@ Two lines are needed in the config.yml : ```yaml type: "Lidarr", "Prowlarr", "Radarr" or "Sonarr" - apikey: "01234deb70424befb1f4ef6a23456789" + apikey: "<---insert-api-key-here--->" ``` The url must be the root url of Lidarr, Prowlarr, Radarr or Sonarr application. @@ -108,7 +109,7 @@ If you are using an older version of Radarr or Sonarr which don't support the ne - name: "Radarr" type: "Radarr" url: "http://localhost:7878/" - apikey: "MY-SUPER-SECRET-API-KEY" + apikey: "<---insert-api-key-here--->" target: "_blank" legacyApi: true ``` @@ -119,7 +120,7 @@ This service displays total number of documents stored. Two lines are required: ```yaml type: "PaperlessNG" - apikey: "0123456789abcdef123456789abcdef" + apikey: "<---insert-api-key-here--->" ``` API key can be generated in Settings > Administration > Auth Tokens @@ -175,7 +176,7 @@ See https://docs.portainer.io/v/ce-2.11/user/account-settings#access-tokens logo: "assets/tools/sample.png" url: "http://192.168.0.151/" type: "Portainer" - apikey: "MY-SUPER-SECRET-API-KEY" + apikey: "<---insert-api-key-here--->" # environments: # - "raspberry" # - "local" @@ -190,7 +191,7 @@ You need to set the type to Emby, provide an api key and choose which stats to s logo: "assets/tools/sample.png" url: "http://192.168.0.151/" type: "Emby" - apikey: "MY-SUPER-SECRET-API-KEY" + apikey: "<---insert-api-key-here--->" libraryType: "music" #Choose which stats to show. Can be one of: music, series or movies. ``` @@ -220,7 +221,7 @@ the "Web Interface" section of settings on the Tautulli web UI. logo: "assets/tools/sample.png" url: "http://192.168.0.151:8181" type: "Tautulli" - apikey: "MY-SUPER-SECRET-API-KEY" + apikey: "<---insert-api-key-here--->" ``` Because the service type and link don't necessarily have to match, you could @@ -233,7 +234,7 @@ endpoint pointing to Tautulli! url: "http://192.168.0.151:32400/web" # Plex endpoint: "http://192.168.0.151:8181" # Tautulli type: "Tautulli" - apikey: "MY-SUPER-SECRET-API-KEY" + apikey: "<---insert-api-key-here--->" ``` ## Mealie @@ -248,7 +249,7 @@ Two lines are needed in the config.yml : ```yaml type: "Healthchecks" - apikey: "01234deb70424befb1f4ef6a23456789" + apikey: "<---insert-api-key-here--->" ``` The url must be the root url of the Healthchecks application. @@ -377,3 +378,16 @@ the "Config" > "General" section of the SABnzbd config in the SABnzbd web UI. apikey: "MY-SUPER-SECRET-API-KEY" downloadInterval: 5000 # (Optional) Interval (in ms) for updating the download count ``` + +## OctoPrint + +The OctoPrint service only needs an `apikey` & `url` and optionally a `display` option. + +```yaml +- name: "Octoprint" + logo: "https://cdn-icons-png.flaticon.com/512/3112/3112529.png" + apikey: "xxxxxxxxxxxx" # insert your own API key here. Request one from https://openweathermap.org/api. + url: "http://192.168.0.151:8080" + display: "text" # 'text' or 'bar'. Default to `text`. + type: "OctoPrint" +``` \ No newline at end of file diff --git a/dummy-data/README.md b/dummy-data/README.md index 6db4712..78b2243 100644 --- a/dummy-data/README.md +++ b/dummy-data/README.md @@ -3,6 +3,12 @@ This directory content makes possible to test custom services cards or create a demo without actually running the service. The principle is simple: save a sample output of the API used in the service in a static file in this directory. The path must be identical as the service endpoint to be used seamlessly. +## Start the mock server to expose dummy data + +```sh +yarn mock +``` + ## How to add a new services sample - create a directory for your service, and any sub-folder existing in the service api path. diff --git a/dummy-data/octoprint/api/job b/dummy-data/octoprint/api/job new file mode 100644 index 0000000..c1ec6ed --- /dev/null +++ b/dummy-data/octoprint/api/job @@ -0,0 +1,30 @@ +{ + "job": { + "averagePrintTime": 669.3131185749999, + "estimatedPrintTime": 314.87566979223726, + "filament": { + "tool0": { + "length": 134.81171000000032, + "volume": 0.0 + } + }, + "file": { + "date": 1665547748, + "display": "CE3PRO_3mmX3mm Brass insert V2.gcode", + "name": "CE3PRO_3mmX3mm Brass insert V2.gcode", + "origin": "local", + "path": "MISC/CE3PRO_3mmX3mm Brass insert V2.gcode", + "size": 129581 + }, + "lastPrintTime": 669.3131185749999, + "user": "friendlyngeeks" + }, + "progress": { + "completion": 27.456185706237797, + "filepos": 35578, + "printTime": 460, + "printTimeLeft": 4612, + "printTimeLeftOrigin": "linear" + }, + "state": "Printing" +} \ No newline at end of file diff --git a/dummy-data/octoprint/api/status_printer_offline-error.json b/dummy-data/octoprint/api/status_printer_offline-error.json new file mode 100644 index 0000000..10fa163 --- /dev/null +++ b/dummy-data/octoprint/api/status_printer_offline-error.json @@ -0,0 +1,26 @@ +{ + "error": "SerialException: device reports readiness to read but returned no data (device disconnected or multiple access on port?)", + "job": { + "averagePrintTime": null, + "estimatedPrintTime": null, + "filament": null, + "file": { + "date": null, + "display": null, + "name": null, + "origin": null, + "path": null, + "size": null + }, + "lastPrintTime": null, + "user": null + }, + "progress": { + "completion": null, + "filepos": null, + "printTime": null, + "printTimeLeft": null, + "printTimeLeftOrigin": null + }, + "state": "Offline after error" +} \ No newline at end of file diff --git a/dummy-data/octoprint/api/status_printer_offline.json b/dummy-data/octoprint/api/status_printer_offline.json new file mode 100644 index 0000000..c733409 --- /dev/null +++ b/dummy-data/octoprint/api/status_printer_offline.json @@ -0,0 +1,26 @@ +{ + "job": { + "estimatedPrintTime": null, + "filament": { + "length": null, + "volume": null + }, + "file": { + "date": null, + "name": null, + "origin": null, + "path": null, + "size": null + }, + "lastPrintTime": null, + "user": null + }, + "progress": { + "completion": null, + "filepos": null, + "printTime": null, + "printTimeLeft": null, + "printTimeOrigin": null + }, + "state": "Offline" +} \ No newline at end of file diff --git a/dummy-data/octoprint/api/status_printer_operational.json b/dummy-data/octoprint/api/status_printer_operational.json new file mode 100644 index 0000000..993d798 --- /dev/null +++ b/dummy-data/octoprint/api/status_printer_operational.json @@ -0,0 +1,26 @@ +{ + "job": { + "estimatedPrintTime": null, + "filament": { + "length": null, + "volume": null + }, + "file": { + "date": null, + "name": null, + "origin": null, + "path": null, + "size": null + }, + "lastPrintTime": null, + "user": null + }, + "progress": { + "completion": null, + "filepos": null, + "printTime": null, + "printTimeLeft": null, + "printTimeOrigin": null + }, + "state": "Operational" +} \ No newline at end of file diff --git a/dummy-data/octoprint/api/status_printer_printing.json b/dummy-data/octoprint/api/status_printer_printing.json new file mode 100644 index 0000000..09cf3cf --- /dev/null +++ b/dummy-data/octoprint/api/status_printer_printing.json @@ -0,0 +1,30 @@ +{ + "job": { + "averagePrintTime": 669.3131185749999, + "estimatedPrintTime": 314.87566979223726, + "filament": { + "tool0": { + "length": 134.81171000000032, + "volume": 0.0 + } + }, + "file": { + "date": 1665547748, + "display": "CE3PRO_3mmX3mm Brass insert V2.gcode", + "name": "CE3PRO_3mmX3mm Brass insert V2.gcode", + "origin": "local", + "path": "MISC/CE3PRO_3mmX3mm Brass insert V2.gcode", + "size": 129581 + }, + "lastPrintTime": 669.3131185749999, + "user": "friendlyngeeks" + }, + "progress": { + "completion": 0.1551153332664511, + "filepos": 201, + "printTime": 0, + "printTimeLeft": 668, + "printTimeLeftOrigin": "average" + }, + "state": "Printing" +} \ No newline at end of file diff --git a/dummy-data/octoprint/api/status_printer_printing_1of2.json b/dummy-data/octoprint/api/status_printer_printing_1of2.json new file mode 100644 index 0000000..09cf3cf --- /dev/null +++ b/dummy-data/octoprint/api/status_printer_printing_1of2.json @@ -0,0 +1,30 @@ +{ + "job": { + "averagePrintTime": 669.3131185749999, + "estimatedPrintTime": 314.87566979223726, + "filament": { + "tool0": { + "length": 134.81171000000032, + "volume": 0.0 + } + }, + "file": { + "date": 1665547748, + "display": "CE3PRO_3mmX3mm Brass insert V2.gcode", + "name": "CE3PRO_3mmX3mm Brass insert V2.gcode", + "origin": "local", + "path": "MISC/CE3PRO_3mmX3mm Brass insert V2.gcode", + "size": 129581 + }, + "lastPrintTime": 669.3131185749999, + "user": "friendlyngeeks" + }, + "progress": { + "completion": 0.1551153332664511, + "filepos": 201, + "printTime": 0, + "printTimeLeft": 668, + "printTimeLeftOrigin": "average" + }, + "state": "Printing" +} \ No newline at end of file diff --git a/dummy-data/octoprint/api/status_printer_printing_2of2.json b/dummy-data/octoprint/api/status_printer_printing_2of2.json new file mode 100644 index 0000000..2acf861 --- /dev/null +++ b/dummy-data/octoprint/api/status_printer_printing_2of2.json @@ -0,0 +1,30 @@ +{ + "job": { + "averagePrintTime": 669.3131185749999, + "estimatedPrintTime": 314.87566979223726, + "filament": { + "tool0": { + "length": 134.81171000000032, + "volume": 0.0 + } + }, + "file": { + "date": 1665547748, + "display": "CE3PRO_3mmX3mm Brass insert V2.gcode", + "name": "CE3PRO_3mmX3mm Brass insert V2.gcode", + "origin": "local", + "path": "MISC/CE3PRO_3mmX3mm Brass insert V2.gcode", + "size": 129581 + }, + "lastPrintTime": 669.3131185749999, + "user": "friendlyngeeks" + }, + "progress": { + "completion": 27.456185706237797, + "filepos": 35578, + "printTime": 476, + "printTimeLeft": 1612, + "printTimeLeftOrigin": "linear" + }, + "state": "Printing" +} \ No newline at end of file diff --git a/dummy-data/octoprint/api/status_printing_completion.json b/dummy-data/octoprint/api/status_printing_completion.json new file mode 100644 index 0000000..55728ba --- /dev/null +++ b/dummy-data/octoprint/api/status_printing_completion.json @@ -0,0 +1,30 @@ +{ + "job": { + "averagePrintTime": 698.814525153, + "estimatedPrintTime": 314.87566979223726, + "filament": { + "tool0": { + "length": 134.81171000000032, + "volume": 0.0 + } + }, + "file": { + "date": 1665547748, + "display": "CE3PRO_3mmX3mm Brass insert V2.gcode", + "name": "CE3PRO_3mmX3mm Brass insert V2.gcode", + "origin": "local", + "path": "MISC/CE3PRO_3mmX3mm Brass insert V2.gcode", + "size": 129581 + }, + "lastPrintTime": 728.315931731, + "user": "friendlyngeeks" + }, + "progress": { + "completion": 100.0, + "filepos": 129581, + "printTime": 728, + "printTimeLeft": 0, + "printTimeLeftOrigin": null + }, + "state": "Operational" +} \ No newline at end of file diff --git a/dummy-data/speedtesttracker/api/speedtest/latest b/dummy-data/speedtesttracker/api/speedtest/latest new file mode 100644 index 0000000..c8e3c1e --- /dev/null +++ b/dummy-data/speedtesttracker/api/speedtest/latest @@ -0,0 +1,7 @@ +{ + "data": { + "download": 42.452234, + "upload": 34.3948, + "ping": 12.9873 + } +} \ No newline at end of file diff --git a/package.json b/package.json index 93953c1..c97dc56 100644 --- a/package.json +++ b/package.json @@ -3,6 +3,7 @@ "version": "22.07.2", "scripts": { "dev": "vite", + "mock": "http-server dummy-data/ --cors", "build": "vite build", "preview": "vite preview --port 5050", "lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs --fix --ignore-path .gitignore" @@ -10,9 +11,9 @@ "dependencies": { "@fortawesome/fontawesome-free": "^6.2.0", "bulma": "^0.9.4", - "yaml": "^2.1.3", "lodash.merge": "^4.6.2", - "vue": "^3.2.41" + "vue": "^3.2.41", + "yaml": "^2.1.3" }, "devDependencies": { "@rushstack/eslint-patch": "^1.2.0", @@ -20,6 +21,7 @@ "@vue/eslint-config-prettier": "^7.0.0", "eslint": "^8.26.0", "eslint-plugin-vue": "^9.6.0", + "http-server": "^14.1.1", "prettier": "^2.7.1", "sass": "^1.55.0", "vite": "^3.2.1", diff --git a/public/assets/config-demo.yml.dist b/public/assets/config-demo.yml.dist index 4d088cc..22dd3b0 100644 --- a/public/assets/config-demo.yml.dist +++ b/public/assets/config-demo.yml.dist @@ -93,6 +93,11 @@ services: - name: "Tools" icon: "fa-solid fa-screwdriver-wrench" items: + - name: "Octoprint" + logo: "https://cdn-icons-png.flaticon.com/512/3112/3112529.png" + apikey: "xxxxxxxxxxxx" + endpoint: "https://homer-demo-content.netlify.app/octoprint" + type: "OctoPrint" - name: "Example item" logo: "assets/tools/sample.png" subtitle: "This another example" diff --git a/src/assets/app.scss b/src/assets/app.scss index d112482..4ce417a 100644 --- a/src/assets/app.scss +++ b/src/assets/app.scss @@ -1,8 +1,8 @@ @charset "utf-8"; @import "./webfonts/webfonts.scss"; - @import "../../node_modules/bulma/bulma"; +@import "./components/status.scss"; // Themes import @import "./themes/sui.scss"; diff --git a/src/assets/components/status.scss b/src/assets/components/status.scss new file mode 100644 index 0000000..b5fd20b --- /dev/null +++ b/src/assets/components/status.scss @@ -0,0 +1,48 @@ +.status { + font-size: 0.8rem; + color: var(--text-title); + + &.offline:before, &.error:before { + background-color: #d65c68; + box-shadow: 0 0 5px 1px #d65c68; + color: #d65c68; + } + + &.pending:before { + background-color: #e8bb7d; + box-shadow: 0 0 5px 1px #e8bb7d; + } + + &.online:before, &.ready:before { + background-color: #94e185; + box-shadow: 0 0 5px 1px #94e185; + } + + &.in-progress:before { + background-color: #8fe87d; + box-shadow: 0 0 5px 1px #8fe87d; + animation: pulse 1s alternate infinite; + } + + @keyframes pulse { + 0% { + background: rgba(255, 255, 255, 0.2); + box-shadow: inset 0px 0px 10px 2px rgba(0, 255, 182, 0.3), + 0px 0px 5px 2px rgba(0, 255, 135, 0.2); + } + 100% { + background: rgba(255, 255, 255, 1); + box-shadow: inset 0px 0px 10px 2px rgba(0, 255, 182, 0.5), + 0px 0px 15px 2px rgba(0, 255, 135, 1); + } + } + + &:before { + content: " "; + display: inline-block; + width: 8px; + height: 8px; + margin-right: 10px; + border-radius: 8px; + } + } \ No newline at end of file diff --git a/src/components/services/OctoPrint.vue b/src/components/services/OctoPrint.vue new file mode 100644 index 0000000..c5da8d9 --- /dev/null +++ b/src/components/services/OctoPrint.vue @@ -0,0 +1,108 @@ + + + + + diff --git a/yarn.lock b/yarn.lock index 1a2d7ed..ec9d0c0 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1269,6 +1269,13 @@ argparse@^2.0.1: resolved "https://registry.yarnpkg.com/argparse/-/argparse-2.0.1.tgz#246f50f3ca78a3240f6c997e8a9bd1eac49e4b38" integrity sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q== +async@^2.6.4: + version "2.6.4" + resolved "https://registry.yarnpkg.com/async/-/async-2.6.4.tgz#706b7ff6084664cd7eae713f6f965433b5504221" + integrity sha512-mzo5dfJYwAn29PeiJ0zvwTo04zj8HDJj0Mn8TD7sno7q12prdbnasKJHhkm2c1LgrhlJ0teaea8860oxi51mGA== + dependencies: + lodash "^4.17.14" + async@^3.2.3: version "3.2.4" resolved "https://registry.yarnpkg.com/async/-/async-3.2.4.tgz#2d22e00f8cddeb5fde5dd33522b56d1cf569a81c" @@ -1315,6 +1322,13 @@ balanced-match@^1.0.0: resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== +basic-auth@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/basic-auth/-/basic-auth-2.0.1.tgz#b998279bf47ce38344b4f3cf916d4679bbf51e3a" + integrity sha512-NF+epuEdnUYVlGuhaxbbq+dvJttwLnGY+YixlXlME5KpQ5W3CnXA5cVTneY3SPbPDRkcjMbifrwmFYcClgOZeg== + dependencies: + safe-buffer "5.1.2" + binary-extensions@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.2.0.tgz#75f502eeaf9ffde42fc98829645be4ea76bd9e2d" @@ -1399,7 +1413,7 @@ chalk@^2.0.0: escape-string-regexp "^1.0.5" supports-color "^5.3.0" -chalk@^4.0.0, chalk@^4.0.2: +chalk@^4.0.0, chalk@^4.0.2, chalk@^4.1.2: version "4.1.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== @@ -1476,6 +1490,11 @@ core-js-compat@^3.21.0, core-js-compat@^3.22.1: browserslist "^4.21.0" semver "7.0.0" +corser@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/corser/-/corser-2.0.1.tgz#8eda252ecaab5840dcd975ceb90d9370c819ff87" + integrity sha512-utCYNzRSQIZNPIcGZdQc92UVJYAhtGAteCFg0yRaFm8f0P+CPtyGyHXJcGXnffjCybUCEx3FQ2G7U3/o9eIkVQ== + cross-spawn@^7.0.2: version "7.0.3" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.3.tgz#f73a85b9d5d41d045551c177e2882d4ac85728a6" @@ -1500,6 +1519,13 @@ csstype@^2.6.8: resolved "https://registry.yarnpkg.com/csstype/-/csstype-2.6.20.tgz#9229c65ea0b260cf4d3d997cb06288e36a8d6dda" integrity sha512-/WwNkdXfckNgw6S5R125rrW8ez139lBHWouiBvX8dfMFtcn6V81REDqnH7+CRpRipfYlyU1CmOnOxrmGcFOjeA== +debug@^3.2.7: + version "3.2.7" + resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.7.tgz#72580b7e9145fb39b6676f9c5e5fb100b934179a" + integrity sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ== + dependencies: + ms "^2.1.1" + debug@^4.1.0, debug@^4.1.1, debug@^4.3.2, debug@^4.3.4: version "4.3.4" resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" @@ -1872,6 +1898,11 @@ esutils@^2.0.2: resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== +eventemitter3@^4.0.0: + version "4.0.7" + resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.7.tgz#2de9b68f6528d5644ef5c59526a1b4a07306169f" + integrity sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw== + fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: version "3.1.3" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" @@ -1952,6 +1983,11 @@ flatted@^3.1.0: resolved "https://registry.yarnpkg.com/flatted/-/flatted-3.2.6.tgz#022e9218c637f9f3fc9c35ab9c9193f05add60b2" integrity sha512-0sQoMh9s0BYsm+12Huy/rkKxVu4R1+r96YX5cG44rHV0pQ6iC3Q+mkoMFaGWObMFYQxCVT+ssG1ksneA2MI9KQ== +follow-redirects@^1.0.0: + version "1.15.2" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.2.tgz#b460864144ba63f2681096f274c4e57026da2c13" + integrity sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA== + fs-extra@^9.0.1: version "9.1.0" resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-9.1.0.tgz#5954460c764a8da2094ba3554bf839e6b9a7c86d" @@ -2108,6 +2144,53 @@ has@^1.0.3: dependencies: function-bind "^1.1.1" +he@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/he/-/he-1.2.0.tgz#84ae65fa7eafb165fddb61566ae14baf05664f0f" + integrity sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw== + +html-encoding-sniffer@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/html-encoding-sniffer/-/html-encoding-sniffer-3.0.0.tgz#2cb1a8cf0db52414776e5b2a7a04d5dd98158de9" + integrity sha512-oWv4T4yJ52iKrufjnyZPkrN0CH3QnrUqdB6In1g5Fe1mia8GmF36gnfNySxoZtxD5+NmYw1EElVXiBk93UeskA== + dependencies: + whatwg-encoding "^2.0.0" + +http-proxy@^1.18.1: + version "1.18.1" + resolved "https://registry.yarnpkg.com/http-proxy/-/http-proxy-1.18.1.tgz#401541f0534884bbf95260334e72f88ee3976549" + integrity sha512-7mz/721AbnJwIVbnaSv1Cz3Am0ZLT/UBwkC92VlxhXv/k/BBQfM2fXElQNC27BVGr0uwUpplYPQM9LnaBMR5NQ== + dependencies: + eventemitter3 "^4.0.0" + follow-redirects "^1.0.0" + requires-port "^1.0.0" + +http-server@^14.1.1: + version "14.1.1" + resolved "https://registry.yarnpkg.com/http-server/-/http-server-14.1.1.tgz#d60fbb37d7c2fdff0f0fbff0d0ee6670bd285e2e" + integrity sha512-+cbxadF40UXd9T01zUHgA+rlo2Bg1Srer4+B4NwIHdaGxAGGv59nYRnGGDJ9LBk7alpS0US+J+bLLdQOOkJq4A== + dependencies: + basic-auth "^2.0.1" + chalk "^4.1.2" + corser "^2.0.1" + he "^1.2.0" + html-encoding-sniffer "^3.0.0" + http-proxy "^1.18.1" + mime "^1.6.0" + minimist "^1.2.6" + opener "^1.5.1" + portfinder "^1.0.28" + secure-compare "3.0.1" + union "~0.5.0" + url-join "^4.0.1" + +iconv-lite@0.6.3: + version "0.6.3" + resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.6.3.tgz#a52f80bf38da1952eb5c681790719871a1a72501" + integrity sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw== + dependencies: + safer-buffer ">= 2.1.2 < 3.0.0" + idb@^7.0.1: version "7.1.0" resolved "https://registry.yarnpkg.com/idb/-/idb-7.1.0.tgz#2cc886be57738419e57f9aab58f647e5e2160270" @@ -2414,7 +2497,7 @@ lodash.sortby@^4.7.0: resolved "https://registry.yarnpkg.com/lodash.sortby/-/lodash.sortby-4.7.0.tgz#edd14c824e2cc9c1e0b0a1b42bb5210516a42438" integrity sha512-HDWXG8isMntAyRF5vZ7xKuEvOhT4AhlRt/3czTSjvGUxjYCBVRQY48ViDHyfYz9VIoBkW4TMGQNapx+l3RUwdA== -lodash@^4.17.20, lodash@^4.17.21: +lodash@^4.17.14, lodash@^4.17.20, lodash@^4.17.21: version "4.17.21" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== @@ -2451,6 +2534,11 @@ micromatch@^4.0.4: braces "^3.0.2" picomatch "^2.3.1" +mime@^1.6.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/mime/-/mime-1.6.0.tgz#32cd9e5c64553bd58d19a568af452acff04981b1" + integrity sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg== + minimatch@^3.0.4, minimatch@^3.0.5, minimatch@^3.1.1, minimatch@^3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" @@ -2465,11 +2553,28 @@ minimatch@^5.0.1: dependencies: brace-expansion "^2.0.1" +minimist@^1.2.6: + version "1.2.7" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.7.tgz#daa1c4d91f507390437c6a8bc01078e7000c4d18" + integrity sha512-bzfL1YUZsP41gmu/qjrEk0Q6i2ix/cVeAhbCbqH9u3zYutS1cLg00qhrD0M2MVdCcx4Sc0UpP2eBWo9rotpq6g== + +mkdirp@^0.5.6: + version "0.5.6" + resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.6.tgz#7def03d2432dcae4ba1d611445c48396062255f6" + integrity sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw== + dependencies: + minimist "^1.2.6" + ms@2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== +ms@^2.1.1: + version "2.1.3" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" + integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== + nanoid@^3.3.4: version "3.3.4" resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.4.tgz#730b67e3cd09e2deacf03c027c81c9d9dbc5e8ab" @@ -2524,6 +2629,11 @@ once@^1.3.0: dependencies: wrappy "1" +opener@^1.5.1: + version "1.5.2" + resolved "https://registry.yarnpkg.com/opener/-/opener-1.5.2.tgz#5d37e1f35077b9dcac4301372271afdeb2a13598" + integrity sha512-ur5UIdyw5Y7yEj9wLzhqXiy6GZ3Mwx0yGI+5sMn2r0N0v3cKJvUmFH5yPP+WXh9e0xfyzyJX95D8l088DNFj7A== + optionator@^0.9.1: version "0.9.1" resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.9.1.tgz#4f236a6373dae0566a6d43e1326674f50c291499" @@ -2587,6 +2697,15 @@ picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.2.2, picomatch@^2.3.1: resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== +portfinder@^1.0.28: + version "1.0.32" + resolved "https://registry.yarnpkg.com/portfinder/-/portfinder-1.0.32.tgz#2fe1b9e58389712429dc2bea5beb2146146c7f81" + integrity sha512-on2ZJVVDXRADWE6jnQaX0ioEylzgBpQk8r55NE4wjXW1ZxO+BgDlY6DXwj20i0V8eB4SenDQ00WEaxfiIQPcxg== + dependencies: + async "^2.6.4" + debug "^3.2.7" + mkdirp "^0.5.6" + postcss-selector-parser@^6.0.9: version "6.0.10" resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-6.0.10.tgz#79b61e2c0d1bfc2602d549e11d0876256f8df88d" @@ -2645,6 +2764,13 @@ punycode@^2.1.0: resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== +qs@^6.4.0: + version "6.11.0" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.0.tgz#fd0d963446f7a65e1367e01abd85429453f0c37a" + integrity sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q== + dependencies: + side-channel "^1.0.4" + queue-microtask@^1.2.2: version "1.2.3" resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" @@ -2731,6 +2857,11 @@ require-from-string@^2.0.2: resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-2.0.2.tgz#89a7fdd938261267318eafe14f9c32e598c36909" integrity sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw== +requires-port@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" + integrity sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ== + resolve-from@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" @@ -2788,15 +2919,20 @@ run-parallel@^1.1.9: dependencies: queue-microtask "^1.2.2" +safe-buffer@5.1.2, safe-buffer@~5.1.1: + version "5.1.2" + resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" + integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== + safe-buffer@^5.1.0: version "5.2.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== -safe-buffer@~5.1.1: - version "5.1.2" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" - integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== +"safer-buffer@>= 2.1.2 < 3.0.0": + version "2.1.2" + resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" + integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== sass@^1.55.0: version "1.55.0" @@ -2807,6 +2943,11 @@ sass@^1.55.0: immutable "^4.0.0" source-map-js ">=0.6.2 <2.0.0" +secure-compare@3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/secure-compare/-/secure-compare-3.0.1.tgz#f1a0329b308b221fae37b9974f3d578d0ca999e3" + integrity sha512-AckIIV90rPDcBcglUwXPF3kg0P0qmPsPXAj6BBEENQE1p5yA1xfmDJzfi1Tappj37Pv2mVbKpL3Z1T+Nn7k1Qw== + semver@7.0.0: version "7.0.0" resolved "https://registry.yarnpkg.com/semver/-/semver-7.0.0.tgz#5f3ca35761e47e05b206c6daff2cf814f0316b8e" @@ -3058,6 +3199,13 @@ unicode-property-aliases-ecmascript@^2.0.0: resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-2.0.0.tgz#0a36cb9a585c4f6abd51ad1deddb285c165297c8" integrity sha512-5Zfuy9q/DFr4tfO7ZPeVXb1aPoeQSdeFMLpYuFebehDAhbuevLs5yxSZmIFN1tP5F9Wl4IpJrYojg85/zgyZHQ== +union@~0.5.0: + version "0.5.0" + resolved "https://registry.yarnpkg.com/union/-/union-0.5.0.tgz#b2c11be84f60538537b846edb9ba266ba0090075" + integrity sha512-N6uOhuW6zO95P3Mel2I2zMsbsanvvtgn6jVqJv4vbVcz/JN0OkL9suomjQGmWtxJQXOCqUJvquc1sMeNz/IwlA== + dependencies: + qs "^6.4.0" + unique-string@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/unique-string/-/unique-string-2.0.0.tgz#39c6451f81afb2749de2b233e3f7c5e8843bd89d" @@ -3090,6 +3238,11 @@ uri-js@^4.2.2: dependencies: punycode "^2.1.0" +url-join@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/url-join/-/url-join-4.0.1.tgz#b642e21a2646808ffa178c4c5fda39844e12cde7" + integrity sha512-jk1+QP6ZJqyOiuEI9AEWQfju/nB2Pw466kbA0LEZljHwKeMgd9WrAEgEGxjPDD2+TNbbb37rTyhEfrCXfuKXnA== + util-deprecate@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" @@ -3148,6 +3301,13 @@ webidl-conversions@^4.0.2: resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-4.0.2.tgz#a855980b1f0b6b359ba1d5d9fb39ae941faa63ad" integrity sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg== +whatwg-encoding@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/whatwg-encoding/-/whatwg-encoding-2.0.0.tgz#e7635f597fd87020858626805a2729fa7698ac53" + integrity sha512-p41ogyeMUrw3jWclHWTQg1k05DSVXPLcVxRTYsXUk+ZooOCZLcoYgPZ/HL/D/N+uQPOtcp1me1WhBEaX02mhWg== + dependencies: + iconv-lite "0.6.3" + whatwg-url@^7.0.0: version "7.1.0" resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-7.1.0.tgz#c2c492f1eca612988efd3d2266be1b9fc6170d06" From bad762c000c00efa4062b8c4704e071a711160a5 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Wed, 7 Dec 2022 22:48:38 +0100 Subject: [PATCH 094/435] Add missing data for proxmox demo --- dummy-data/proxmox/api2/json/nodes/node1/lxc | 35 ++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 dummy-data/proxmox/api2/json/nodes/node1/lxc diff --git a/dummy-data/proxmox/api2/json/nodes/node1/lxc b/dummy-data/proxmox/api2/json/nodes/node1/lxc new file mode 100644 index 0000000..35e1d2f --- /dev/null +++ b/dummy-data/proxmox/api2/json/nodes/node1/lxc @@ -0,0 +1,35 @@ +{ + "data": [{ + "disk": 0, + "mem": 983848043, + "cpus": 2, + "pid": 1218, + "maxdisk": 107374182400, + "netin": 43863882954, + "diskread": 0, + "diskwrite": 0, + "name": "HAOS", + "netout": 10426448652, + "cpu": 0.00879886290177172, + "uptime": 3390069, + "status": "running", + "maxmem": 3221225472, + "vmid": 100 + }, { + "cpu": 0.00219971572544293, + "name": "debian1", + "netout": 919020028, + "vmid": 101, + "maxmem": 4294967296, + "uptime": 3390064, + "status": "running", + "maxdisk": 107374182400, + "pid": 1295, + "cpus": 2, + "disk": 0, + "mem": 2755160795, + "diskread": 0, + "diskwrite": 0, + "netin": 5105600872 + }] +} \ No newline at end of file From 71759ad6fb984bcfc14d8b05b60d08a2dee5a041 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Tue, 20 Dec 2022 19:55:11 +0100 Subject: [PATCH 095/435] Update issue templates --- .github/ISSUE_TEMPLATE/bug_report.md | 28 +++++++++++++++++++++++ .github/ISSUE_TEMPLATE/feature_request.md | 20 ++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 .github/ISSUE_TEMPLATE/bug_report.md create mode 100644 .github/ISSUE_TEMPLATE/feature_request.md diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 0000000..e9fd38a --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,28 @@ +--- +name: Bug report +about: Create a report to help us improve +title: '' +labels: '' +assignees: '' + +--- + +**Describe the bug** +A clear and concise description of what the bug is. + +**Expected behavior** +A clear and concise description of what you expected to happen. + +**Logs & errors** +Please include any usefull information: +- Errors in your browser console (`ctrl+shift+i` or `F12`) +- If applicable, your docker container logs. + +**Screenshots** +If applicable, add screenshots to help explain your problem. + +**Configuration** +If applicable, copy related homer yaml configuration here. +```yml + +``` diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md new file mode 100644 index 0000000..bbcbbe7 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,20 @@ +--- +name: Feature request +about: Suggest an idea for this project +title: '' +labels: '' +assignees: '' + +--- + +**Is your feature request related to a problem? Please describe.** +A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] + +**Describe the solution you'd like** +A clear and concise description of what you want to happen. + +**Describe alternatives you've considered** +A clear and concise description of any alternative solutions or features you've considered. + +**Additional context** +Add any other context or screenshots about the feature request here. From bd122e270060b5548313ab1d7d520939e62d52fd Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Tue, 20 Dec 2022 19:56:33 +0100 Subject: [PATCH 096/435] Create FUNDING.yml --- .github/FUNDING.yml | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 .github/FUNDING.yml diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 0000000..36e6b30 --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1,3 @@ +# These are supported funding model platforms + +custom: ['https://www.buymeacoffee.com/bastien'] From 53726ecc1ad039f70b37647865d1d03fb0b87395 Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Tue, 20 Dec 2022 20:26:34 +0100 Subject: [PATCH 097/435] Fix typo in demo page (#574) --- dummy-data/_headers | 3 ++- public/assets/config-demo.yml.dist | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/dummy-data/_headers b/dummy-data/_headers index e26ac79..9884812 100644 --- a/dummy-data/_headers +++ b/dummy-data/_headers @@ -1,4 +1,5 @@ /* Content-Type: application/json Access-Control-Allow-Origin: https://homer-demo.netlify.app - Access-Control-Allow-Headers: Authorization \ No newline at end of file + Access-Control-Allow-Headers: Authorization + Access-Control-Allow-Methods: GET, OPTIONS \ No newline at end of file diff --git a/public/assets/config-demo.yml.dist b/public/assets/config-demo.yml.dist index 22dd3b0..ac2b411 100644 --- a/public/assets/config-demo.yml.dist +++ b/public/assets/config-demo.yml.dist @@ -115,9 +115,9 @@ services: icon: "fas fa-solid fa-arrow-up-right-from-square" items: - name: "Buy me a coffee !" - subtitle: "If you want to support me, but me a coffee " - background: "#AC70DD" - logo: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAACACAYAAADDPmHLAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAADsQAAA7EB9YPtSQAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAAn1SURBVHic7Z19jF1FFcB/S2l3t8vW5UM3FWOoQRADWLZGgRgpBhSxZGv8QIVAhSA1YmJMFDHRxBCjiSaITQzWVC2RBPkWsERj/QgWxUgtFERAcS3YLrJlabe0Zdfd5Y/zbu7MvO99d+bcd+/8ksneue+9O+eee/bMna8zPehwPHAPsBLYB7wMTNb4+yywGTisI2bxOVKp3K8B76wcH1tJ9VgNfLLG+YuBbwO92IbT6DjJJ+fmO7uN7qdHocw+YA8w1OL3x4AVzrlFyEMc7FCWfdQ2kFaOX+mw7Fyg4QFGsR/+JHCocm6p89154Ic1rjGHVAudGsDrKmkhzNDYUJoZ0kwngnczW5AHm6QPGp/1AsPAycCZwIkNrnMO8BvgGeBFRKHzXZQOAM8BO4EHgbuA81rQX6aErgKWA7tIPc9u4M3AbEbXPwo4GvEmQw2Oa322LCMZOuEw8BakigxC6CrgUqfMW8ju4YP8VyX/WQuhHzGGhaS+TgSv0Ifo6DsZXKslQnuAncCpRv404PHAMviij/Y8jvn3GOM6T2DrqDCswq4D/6orTq54BFs3q0IVfESogoDLnfzmgGXnHVcXrq66nsXA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yojgRC2s8ENG/s9ZOVwRNEDhDQA16pXVFKkmkJWAc8GLKvb+UeogkJ6gEeR+fhXIWMDZWcJdtv/IFJNbiCgAUT0uBJ7LGKdhhAhq4CIjcouYS7RAPTIxRzAaAB6qGwU6RINQI/SVwHLkRW5GyhnNE7TAOaxl9CXgl+SvgHfqSyLBrmYAaTpAcwFGe9Sk0IP8x1Axf2DrgHkKWqIBqU3ALPZs5Ry7TDaj32/pTSAMm8p7zYB1VYB5cUDQLkMIBdNQMiXB8jD1OxQRA9A9AAm0QAotweIVQDl9gClNIBYBaSUsgqIL4Ep0QMQPYAK2l3B00b+eC1BFDDvdZoSjgQmPE46IrafAgZFqMFi7JXAj2kKoz0h5FHjeBD4gJYgAbkAezbwDi1B8sBa7JmxDxF+b+GQ9CDRRs17vkhVImWWIBE4TYVcqyqRX9yoZf8lrpHgMmylzAJfVJXID1+iejfTS1Qlygk9wANUB23aCqwGFqlJ1jmLkH0Af0f1/d1PDqo7dQEqLENCuZ5e47NJJGhSt0XOPAZZ/ForEsoOZHeSGCvJYBmyP2+7AR27LW0hhsepyyLgc0i4d+0HlXXaDXwW/aa3RV6qAJcBZD+/UaRaeBP+o3VnzQHgOaSj5xfAvdibVOWC1wAsmcjgl0BqAQAAAABJRU5ErkJggg==" + subtitle: "If you want to support me, buy me a coffee " + logo: "https://www.buymeacoffee.com/assets/img/guidelines/logo-mark-1.svg" + url: "https://www.buymeacoffee.com/bastien" - name: "r/selfhosted" icon: "fa-brands fa-reddit-alien" subtitle: "Bookmark example" From 49c2023b8e7eea6b28113b43beca29ee865faebc Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Tue, 20 Dec 2022 20:47:56 +0100 Subject: [PATCH 098/435] Avoid hidding all info when copy pasting the exemple config --- docs/customservices.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/customservices.md b/docs/customservices.md index 88e4e2f..8b94cad 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -305,7 +305,7 @@ Configuration example: api_token: "PVEAPIToken=root@pam!your-api-token-name=your-api-token-key" # values below this line are optional (default value are false/empty): hide_decimals: true # removes decimals from stats values. - hide: ["vms", "vms_total", "lxcs", "lxcs_total", "disk", "mem", "cpu"] # hides values included in the array + hide: [] # hides information. Possible values are "vms", "vms_total", "lxcs", "lxcs_total", "disk", "mem" and "cpu". small_font_on_small_screens: true # uses small font on small screens (like mobile) small_font_on_desktop: true # uses small font on desktops (just in case you're showing much info) ``` From b7cd8f9482e6836a96b354b11595b03b9c3d67cd Mon Sep 17 00:00:00 2001 From: Bastien Wirtz Date: Tue, 20 Dec 2022 21:19:38 +0100 Subject: [PATCH 099/435] Add Helm installation instructions (#562) --- README.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/README.md b/README.md index 95faada..d69796a 100644 --- a/README.md +++ b/README.md @@ -121,6 +121,23 @@ cp assets/config.yml.dist assets/config.yml npx serve # or python -m http.server 8010 or apache, nginx ... ``` +### Using Helm + +Thanks to [@djjudas21](https://github.com/djjudas21) [charts](https://github.com/djjudas21/charts/tree/main/charts/homer): + +```sh +helm repo add djjudas21 https://djjudas21.github.io/charts/ +helm repo update djjudas21 + +# install with all defaults +helm install homer djjudas21/homer + +# install with customisations +wget https://raw.githubusercontent.com/djjudas21/charts/main/charts/homer/values.yaml +# edit values.yaml +helm install homer djjudas21/homer -f values.yaml +``` + ### Build manually ```sh From 05912080962ad6d0c09bc9f79f82de58663a5fac Mon Sep 17 00:00:00 2001 From: Ivan Barsukov Date: Tue, 7 Feb 2023 08:33:33 +0100 Subject: [PATCH 100/435] Minor doc fixes (#595) --- docs/customservices.md | 2 +- docs/troubleshooting.md | 2 +- dummy-data/README.md | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/customservices.md b/docs/customservices.md index 8b94cad..82114c2 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -167,7 +167,7 @@ For AdGuard Home you need to set the type to AdGuard, if you have somes issues a This service displays info about the total number of containers managed by your Portainer instance. In order to use it, you must be using Portainer version 1.11 or later. Generate an access token from the UI and pass it to the apikey field. -By default, every connected environments will be checked. To select specific ones,add an "environments" entry which can be a simple string or an array containing all the selected environments name. +By default, every connected environments will be checked. To select specific ones, add an "environments" entry which can be a simple string or an array containing all the selected environments name. See https://docs.portainer.io/v/ce-2.11/user/account-settings#access-tokens diff --git a/docs/troubleshooting.md b/docs/troubleshooting.md index 8a0d11d..6ac0b8a 100644 --- a/docs/troubleshooting.md +++ b/docs/troubleshooting.md @@ -10,7 +10,7 @@ $ docker logs homer Assets directory not writable. Check assets directory permissions & docker user or skip default assets install by setting the INIT_ASSETS env var to 0 ``` -In this case you need to make sure your mounted assests directory have the same GID / UID the container user have (default 1000:1000), and that the read and write permission is granted for the user or the group. +In this case you need to make sure your mounted assets directory have the same GID / UID the container user have (default 1000:1000), and that the read and write permission is granted for the user or the group. You can either: - Update your assets directory permissions (ex: `chown -R 1000:1000 /your/assets/folder/`, `chmod -R u+rw /your/assets/folder/`) diff --git a/dummy-data/README.md b/dummy-data/README.md index 78b2243..6a54be3 100644 --- a/dummy-data/README.md +++ b/dummy-data/README.md @@ -18,5 +18,5 @@ Example: ```sh mkdir pihole -curl http://my-pihole.me/admin/api.php -o pihole/api.php # /admin is omited because for PiHole, the implementation expect it to be in the base url (`url` or `endpoint` property) +curl http://my-pihole.me/admin/api.php -o pihole/api.php # /admin is omitted because for PiHole, the implementation expect it to be in the base url (`url` or `endpoint` property) ``` From 1c7451bc81b847cf26cdb60c87b9c6cfffb12a6a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 7 Feb 2023 08:34:49 +0100 Subject: [PATCH 101/435] Bump json5 from 2.2.1 to 2.2.3 (#583) Bumps [json5](https://github.com/json5/json5) from 2.2.1 to 2.2.3. - [Release notes](https://github.com/json5/json5/releases) - [Changelog](https://github.com/json5/json5/blob/main/CHANGELOG.md) - [Commits](https://github.com/json5/json5/compare/v2.2.1...v2.2.3) --- updated-dependencies: - dependency-name: json5 dependency-type: indirect ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- yarn.lock | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/yarn.lock b/yarn.lock index ec9d0c0..abc6cef 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2444,9 +2444,9 @@ json-stable-stringify-without-jsonify@^1.0.1: integrity sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw== json5@^2.2.0, json5@^2.2.1: - version "2.2.1" - resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.1.tgz#655d50ed1e6f95ad1a3caababd2b0efda10b395c" - integrity sha512-1hqLFMSrGHRHxav9q9gNjJ5EXznIxGVO09xQRrwplcS8qs28pZ8s8hupZAmqDwZUmVZ2Qb2jnyPOWcDH8m8dlA== + version "2.2.3" + resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.3.tgz#78cd6f1a19bdc12b73db5ad0c61efd66c1e29283" + integrity sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg== jsonfile@^6.0.1: version "6.1.0" From dfde8ea89d02f59f5408585702c0f2cf3f94eac1 Mon Sep 17 00:00:00 2001 From: Matt Bentley Date: Tue, 7 Feb 2023 02:38:37 -0500 Subject: [PATCH 102/435] Added Tdarr service (#573) * Added Tdarr service Signed-off-by: Matt Bentley * Added dummy-data for Tdarr; remove trailing / for API endpoint Signed-off-by: Matt Bentley --------- Signed-off-by: Matt Bentley --- docs/customservices.md | 16 +- dummy-data/tdarr/api/v2/cruddb | 470 ++++++++++++++++++++++++++++++ src/components/services/Tdarr.vue | 125 ++++++++ 3 files changed, 610 insertions(+), 1 deletion(-) create mode 100644 dummy-data/tdarr/api/v2/cruddb create mode 100644 src/components/services/Tdarr.vue diff --git a/docs/customservices.md b/docs/customservices.md index 82114c2..b28f399 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -32,6 +32,7 @@ within Homer: - [What's Up Docker](#whats-up-docker) - [SABnzbd](#sabnzbd) - [OctoPrint](#sabnzbd) + - [Tdarr](#tdarr) If you experiencing any issue, please have a look to the [troubleshooting](troubleshooting.md) page. @@ -390,4 +391,17 @@ The OctoPrint service only needs an `apikey` & `url` and optionally a `display` url: "http://192.168.0.151:8080" display: "text" # 'text' or 'bar'. Default to `text`. type: "OctoPrint" -``` \ No newline at end of file +``` + +## Tdarr + +The Tdarr service can allow you to show the number of currently queued items +for transcoding on your Tdarr instance as well as the number of errored items. + +```yaml +- name: "Tdarr" + logo: "assets/tools/sample.png" + url: "http://192.168.0.151:8265" + type: "Tdarr" + checkInterval: 5000 # (Optional) Interval (in ms) for updating the queue & error counts +``` diff --git a/dummy-data/tdarr/api/v2/cruddb b/dummy-data/tdarr/api/v2/cruddb new file mode 100644 index 0000000..2af4863 --- /dev/null +++ b/dummy-data/tdarr/api/v2/cruddb @@ -0,0 +1,470 @@ +{ + "totalFileCount": 3245, + "totalTranscodeCount": 3148, + "totalHealthCheckCount": 7278, + "sizeDiff": 5265.423687950708, + "_id": "statistics", + "tdarrScore": "99.97", + "healthCheckScore": "99.97", + "table0Count": 0, + "table2Count": 3244, + "table3Count": 0, + "table4Count": 1, + "table5Count": 3244, + "table6Count": 0, + "table1Count": 1, + "pies": [ + [ + "All", + "all", + 3245, + 3148, + 5265.423687950708, + 7278, + [ + { + "name": "Transcode success", + "value": 1995 + }, + { + "name": "Not required", + "value": 1249 + }, + { + "name": "Queued", + "value": 1 + } + ], + [ + { + "name": "Success", + "value": 3244 + }, + { + "name": "Queued", + "value": 1 + } + ], + [ + { + "name": "hevc", + "value": 3172 + }, + { + "name": "vp9", + "value": 48 + }, + { + "name": "h264", + "value": 24 + } + ], + [ + { + "name": "mkv", + "value": 3115 + }, + { + "name": "webm", + "value": 48 + }, + { + "name": "mp4", + "value": 81 + } + ], + [ + { + "name": "1080p", + "value": 2582 + }, + { + "name": "480p", + "value": 406 + }, + { + "name": "720p", + "value": 224 + }, + { + "name": "4KUHD", + "value": 29 + }, + { + "name": "576p", + "value": 3 + } + ], + [], + [] + ], + [ + "Type1", + "t7_0knr-z", + 3, + 0, + 0, + 3, + [ + { + "name": "Not required", + "value": 3 + } + ], + [ + { + "name": "Success", + "value": 3 + } + ], + [ + { + "name": "hevc", + "value": 3 + } + ], + [ + { + "name": "mkv", + "value": 3 + } + ], + [ + { + "name": "480p", + "value": 3 + } + ], + [], + [] + ], + [ + "Type2", + "ekyBRmWbD", + 9, + 13, + 10.722183834761381, + 65, + [ + { + "name": "Transcode success", + "value": 9 + } + ], + [ + { + "name": "Success", + "value": 9 + } + ], + [ + { + "name": "hevc", + "value": 9 + } + ], + [ + { + "name": "mkv", + "value": 9 + } + ], + [ + { + "name": "480p", + "value": 1 + }, + { + "name": "576p", + "value": 1 + }, + { + "name": "720p", + "value": 4 + }, + { + "name": "1080p", + "value": 3 + } + ], + [], + [] + ], + [ + "Type3", + "-dy1H5yNz", + 2619, + 2641, + 2710.185842271894, + 5837, + [ + { + "name": "Transcode success", + "value": 1586 + }, + { + "name": "Not required", + "value": 1033 + } + ], + [ + { + "name": "Success", + "value": 2619 + } + ], + [ + { + "name": "hevc", + "value": 2571 + }, + { + "name": "vp9", + "value": 48 + } + ], + [ + { + "name": "mkv", + "value": 2510 + }, + { + "name": "webm", + "value": 48 + }, + { + "name": "mp4", + "value": 61 + } + ], + [ + { + "name": "1080p", + "value": 2050 + }, + { + "name": "720p", + "value": 186 + }, + { + "name": "480p", + "value": 383 + } + ], + [], + [] + ], + [ + "Type4", + "ASRD2TAeP", + 1, + 11, + 83.31165281962603, + 32, + [ + { + "name": "Queued", + "value": 1 + } + ], + [ + { + "name": "Queued", + "value": 1 + } + ], + [ + { + "name": "h264", + "value": 1 + } + ], + [ + { + "name": "mp4", + "value": 1 + } + ], + [ + { + "name": "1080p", + "value": 1 + } + ], + [], + [] + ], + [ + "Type5", + "KQ03rLWIw", + 11, + 14, + 17.225701110437512, + 43, + [ + { + "name": "Not required", + "value": 11 + } + ], + [ + { + "name": "Success", + "value": 11 + } + ], + [ + { + "name": "hevc", + "value": 11 + } + ], + [ + { + "name": "mkv", + "value": 11 + } + ], + [ + { + "name": "720p", + "value": 6 + }, + { + "name": "480p", + "value": 4 + }, + { + "name": "1080p", + "value": 1 + } + ], + [], + [] + ], + [ + "Type6", + "RQhHe9OCl", + 602, + 473, + 2420.9242209186777, + 1300, + [ + { + "name": "Not required", + "value": 202 + }, + { + "name": "Transcode success", + "value": 400 + } + ], + [ + { + "name": "Success", + "value": 602 + } + ], + [ + { + "name": "hevc", + "value": 578 + }, + { + "name": "h264", + "value": 23 + } + ], + [ + { + "name": "mkv", + "value": 582 + }, + { + "name": "mp4", + "value": 19 + } + ], + [ + { + "name": "480p", + "value": 15 + }, + { + "name": "1080p", + "value": 527 + }, + { + "name": "4KUHD", + "value": 29 + }, + { + "name": "720p", + "value": 28 + }, + { + "name": "576p", + "value": 2 + } + ], + [], + [] + ] + ], + "streamStats": { + "duration": { + "average": 3127, + "highest": 8548, + "total": 253273 + }, + "bit_rate": { + "average": 2242894, + "highest": 20149278, + "total": 181674395 + }, + "nb_frames": { + "average": 75320, + "highest": 204941, + "total": 6100852 + } + }, + "avgNumberOfStreamsInVideo": 5.049321824907522, + "languages": { + "ara": { + "count": 181 + }, + "est": { + "count": 62 + }, + "lav": { + "count": 62 + }, + "may": { + "count": 131 + }, + "nor": { + "count": 110 + }, + "chi": { + "count": 384 + }, + "ind": { + "count": 63 + }, + "rum": { + "count": 138 + }, + "nob": { + "count": 18 + }, + "srp": { + "count": 3 + } + }, + "DBPollPeriod": "1s", + "DBFetchTime": "1s", + "DBLoadStatus": "Stable", + "DBQueue": 0, + "processWarning": "", + "processWarningQueues": true +} diff --git a/src/components/services/Tdarr.vue b/src/components/services/Tdarr.vue new file mode 100644 index 0000000..a2734f0 --- /dev/null +++ b/src/components/services/Tdarr.vue @@ -0,0 +1,125 @@ + + + + + From d362add383b622c4b941e8bdd02b741393c65bd0 Mon Sep 17 00:00:00 2001 From: Floren Munteanu Date: Sun, 19 Feb 2023 15:18:56 -0500 Subject: [PATCH 103/435] Implement PiHole API token (#580) Implement PiHole API token --- docs/customservices.md | 4 ++++ src/components/services/PiHole.vue | 6 +++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/docs/customservices.md b/docs/customservices.md index b28f399..31d302b 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -58,9 +58,13 @@ The following configuration is available for the PiHole service. logo: "assets/tools/sample.png" # subtitle: "Network-wide Ad Blocking" # optional, if no subtitle is defined, PiHole statistics will be shown url: "http://192.168.0.151/admin" + apikey: "<---insert-api-key-here--->" # optional, needed if web interface is password protected type: "PiHole" ``` +**Remarks:** +If PiHole web interface is password protected, obtain the `apikey` from Settings > API/Web interface > Show API token. + ## OpenWeatherMap Using the OpenWeatherMap service you can display weather information about a given location. diff --git a/src/components/services/PiHole.vue b/src/components/services/PiHole.vue index 9aac016..237cb12 100644 --- a/src/components/services/PiHole.vue +++ b/src/components/services/PiHole.vue @@ -49,7 +49,11 @@ export default { }, methods: { fetchStatus: async function () { - const result = await this.fetch("/api.php").catch((e) => console.log(e)); + const authQueryParams = this.item.apikey + ? `?summaryRaw&auth=${this.item.apikey}` + : ""; + const result = await this.fetch(`/api.php${authQueryParams}`) + .catch((e) => console.log(e)); this.status = result.status; this.ads_percentage_today = result.ads_percentage_today; From 1707f5adaddb90a126be4b60284921facb6d37ff Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 28 Apr 2023 09:36:59 +0200 Subject: [PATCH 104/435] Bump yaml from 2.1.3 to 2.2.2 (#636) Bumps [yaml](https://github.com/eemeli/yaml) from 2.1.3 to 2.2.2. - [Release notes](https://github.com/eemeli/yaml/releases) - [Commits](https://github.com/eemeli/yaml/compare/v2.1.3...v2.2.2) --- updated-dependencies: - dependency-name: yaml dependency-type: direct:production ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- package.json | 2 +- yarn.lock | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index c97dc56..afe350a 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,7 @@ "bulma": "^0.9.4", "lodash.merge": "^4.6.2", "vue": "^3.2.41", - "yaml": "^2.1.3" + "yaml": "^2.2.2" }, "devDependencies": { "@rushstack/eslint-patch": "^1.2.0", diff --git a/yarn.lock b/yarn.lock index abc6cef..1c4b283 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3513,10 +3513,10 @@ yallist@^4.0.0: resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== -yaml@^2.1.3: - version "2.1.3" - resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.1.3.tgz#9b3a4c8aff9821b696275c79a8bee8399d945207" - integrity sha512-AacA8nRULjKMX2DvWvOAdBZMOfQlypSFkjcOcu9FalllIDJ1kvlREzcdIZmidQUqqeMv7jorHjq2HlLv/+c2lg== +yaml@^2.2.2: + version "2.2.2" + resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.2.2.tgz#ec551ef37326e6d42872dad1970300f8eb83a073" + integrity sha512-CBKFWExMn46Foo4cldiChEzn7S7SRV+wqiluAb6xmueD/fGyRHIhX8m14vVGgeFWjN540nKCNVj6P21eQjgTuA== yocto-queue@^0.1.0: version "0.1.0" From 6d2d9baf35b1772409162e86f6d4b7f9374edb2e Mon Sep 17 00:00:00 2001 From: Zach Russell Date: Tue, 2 May 2023 01:27:27 -0600 Subject: [PATCH 105/435] =?UTF-8?q?Fixed=20OctoPrint=20=E2=80=98text?= =?UTF-8?q?=E2=80=99=20display=20when=20idle.=20(#607)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Added moonraker support and temperature when idle * removed config change * Delete package-lock.json --- docs/customservices.md | 12 +++++++----- dummy-data/octoprint/api/printer | 27 +++++++++++++++++++++++++++ src/components/services/OctoPrint.vue | 20 +++++++++++++++++++- 3 files changed, 53 insertions(+), 6 deletions(-) create mode 100644 dummy-data/octoprint/api/printer diff --git a/docs/customservices.md b/docs/customservices.md index 31d302b..665c6f5 100644 --- a/docs/customservices.md +++ b/docs/customservices.md @@ -31,7 +31,7 @@ within Homer: - [Speedtest Tracker](#SpeedtestTracker) - [What's Up Docker](#whats-up-docker) - [SABnzbd](#sabnzbd) - - [OctoPrint](#sabnzbd) + - [OctoPrint](#octoprint) - [Tdarr](#tdarr) If you experiencing any issue, please have a look to the [troubleshooting](troubleshooting.md) page. @@ -384,15 +384,17 @@ the "Config" > "General" section of the SABnzbd config in the SABnzbd web UI. downloadInterval: 5000 # (Optional) Interval (in ms) for updating the download count ``` -## OctoPrint +## OctoPrint/Moonraker -The OctoPrint service only needs an `apikey` & `url` and optionally a `display` option. +The OctoPrint/Moonraker service only needs an `apikey` & `endpoint` and optionally a `display` or `url` option. `url` can be used when you click on the service it will launch the `url` + +Moonraker's API mimmicks a few of OctoPrint's endpoints which makes these services compatible. See https://moonraker.readthedocs.io/en/latest/web_api/#octoprint-api-emulation for details. ```yaml - name: "Octoprint" logo: "https://cdn-icons-png.flaticon.com/512/3112/3112529.png" - apikey: "xxxxxxxxxxxx" # insert your own API key here. Request one from https://openweathermap.org/api. - url: "http://192.168.0.151:8080" + apikey: "xxxxxxxxxxxx" # insert your own API key here. + endpoint: "http://192.168.0.151:8080" display: "text" # 'text' or 'bar'. Default to `text`. type: "OctoPrint" ``` diff --git a/dummy-data/octoprint/api/printer b/dummy-data/octoprint/api/printer new file mode 100644 index 0000000..b8bbe98 --- /dev/null +++ b/dummy-data/octoprint/api/printer @@ -0,0 +1,27 @@ +{ + "temperature": { + "bed": { + "actual": 20.52, + "offset": 0, + "target": 0.0 + }, + "tool0": { + "actual": 20.44, + "offset": 0, + "target": 0.0 + } + }, + "state": { + "text": "Operational", + "flags": { + "operational": true, + "paused": false, + "printing": false, + "cancelling": false, + "pausing": false, + "error": false, + "ready": true, + "closedOrError": false + } + } +} \ No newline at end of file diff --git a/src/components/services/OctoPrint.vue b/src/components/services/OctoPrint.vue index c5da8d9..1428d9a 100644 --- a/src/components/services/OctoPrint.vue +++ b/src/components/services/OctoPrint.vue @@ -6,7 +6,7 @@ -