From 7ffe7e29e22fc627ce31ee89e7a70725fa0c6969 Mon Sep 17 00:00:00 2001 From: Brenner-Bot Date: Mon, 16 May 2022 11:31:35 +0000 Subject: [PATCH] :tada: Release of add-on Cloudflared 2.0.0 --- README.md | 6 +++--- cloudflared/CHANGELOG.md | 16 +++++++++++----- cloudflared/DOCS.md | 24 +++++++++++++++++++++++- cloudflared/config.yaml | 10 ++++++---- cloudflared/translations/en.yaml | 5 +++++ 5 files changed, 48 insertions(+), 13 deletions(-) diff --git a/README.md b/README.md index d8df3bb..aec04a4 100644 --- a/README.md +++ b/README.md @@ -86,10 +86,10 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -[addon-cloudflared]: https://github.com/brenner-tobias/addon-cloudflared/tree/v1.0.5 -[addon-doc-cloudflared]: https://github.com/brenner-tobias/addon-cloudflared/blob/v1.0.5/README.md +[addon-cloudflared]: https://github.com/brenner-tobias/addon-cloudflared/tree/v2.0.0 +[addon-doc-cloudflared]: https://github.com/brenner-tobias/addon-cloudflared/blob/v2.0.0/README.md [cloudflared-issue]: https://github.com/brenner-tobias/addon-cloudflared/issues -[cloudflared-version-shield]: https://img.shields.io/badge/version-v1.0.5-blue.svg +[cloudflared-version-shield]: https://img.shields.io/badge/version-v2.0.0-blue.svg [cloudflared-aarch64-shield]: https://img.shields.io/badge/aarch64-yes-green.svg [cloudflared-amd64-shield]: https://img.shields.io/badge/amd64-yes-green.svg [cloudflared-armhf-shield]: https://img.shields.io/badge/armhf-yes-green.svg diff --git a/cloudflared/CHANGELOG.md b/cloudflared/CHANGELOG.md index 3288648..7fa9b59 100644 --- a/cloudflared/CHANGELOG.md +++ b/cloudflared/CHANGELOG.md @@ -1,11 +1,17 @@ ## What’s changed -- ℹ️ Update Cloudflared to version 2022.5.0 @github-actions (#88) -## 📚 Documentation +## 🚨 New functionality +We now support the use of remotely set up tunnels with this add-on. +Take a look at the [documentation](https://developers.cloudflare.com/cloudflare-one/connections/connect-apps/install-and-setup/tunnel-guide/#set-up-a-tunnel-remotely-dashboard-setup) to see if the new feature is for you and if you want to migrate your tunnel to the new functionality. The current set up process (local managed tunnel) is still fully supported by this add-on. **The update has no effect on existing configurations.** -- Add translations to Add-on configuration page @elcajon (#87) +## 🚀 Enhancements + +- Add remote managed tunnel functionality: The new function allows to use remote managed Cloudflare tunnel with this add-on. @elcajon (#95) ## ⬆️ Dependency updates -- Update yq from 4.14.1-r0 to 4.14.1-r1 @elcajon (#85) -- Bump docker/setup-buildx-action from 1.6.0 to 1.7.0 @dependabot (#84) +- ℹ️ Update Cloudflared to version 2022.5.1 @github-actions (#96) +- Bump docker/login-action from 1.14.1 to 2.0.0 @dependabot (#92) +- Bump docker/setup-buildx-action from 1.7.0 to 2.0.0 @dependabot (#91) +- Bump docker/build-push-action from 2.10.0 to 3.0.0 @dependabot (#90) +- Bump docker/setup-qemu-action from 1.2.0 to 2.0.0 @dependabot (#89) diff --git a/cloudflared/DOCS.md b/cloudflared/DOCS.md index 8a95821..41051b7 100644 --- a/cloudflared/DOCS.md +++ b/cloudflared/DOCS.md @@ -40,8 +40,9 @@ and a manual step at the first set-up. 1. If you don't yet have a working Cloudflare set-up: Get a domain name and set-up Cloudflare. See section [Domain Name and Cloudlfare Set-Up](#domain-name-and-cloudlfare-set-up) for details. +1. **Decide whether to use a [local or managed tunnel][addon-remote-or-local].** -### Initial Add-on Setup +### Initial Add-on Setup for local tunnels The following instructions describe the minimum necessary steps to use this add-on: @@ -76,6 +77,7 @@ Please check the index below for further information. - [`log_level`](#option-log_level) - [`reset_cloudflared_files`](#option-reset_cloudflared_files) - [`warp_reset`](#option-warp_reset) +- [`tunnel_token`](#option-tunnel_token) ### Overview: Add-on Configuration @@ -307,6 +309,22 @@ warp_routes: address spaces (RFC 191), you need to adapt the [Split Tunnel][cloudflared-route-st] configuration._ +### Option: `tunnel_token` + +If you created a Cloudflare Tunnel from the Zero Trust Dashboard, you can provide +your tunnel token to connect to your remote managed tunnel. +Keep in mind, when using this option, that you need to configure all +hosts (including Home Assistant) by yourself. +Set `tunnel_token` to your [tunnel token][create-remote-managed-tunnel], +all other configuration will be ignored. After starting the addon, check the +logs to see whether everything went as expected. + +Check out [this how-to][addon-remote-tunnel] to get a step by step +guide on how to set up a remote managed tunnel with this add-on. + +Please note that you still have to add the `http` integration settings to your +HA-config as described [here](#configurationyaml). + ### Option: `log_level` The `log_level` option controls the level of log output by the addon and can @@ -436,3 +454,7 @@ SOFTWARE. [cloudflared-ingress]: https://developers.cloudflare.com/cloudflare-one/connections/connect-apps/configuration/configuration-file/ingress [cloudflared-route]: https://developers.cloudflare.com/cloudflare-one/connections/connect-networks/private-net/ [cloudflared-route-st]: https://developers.cloudflare.com/cloudflare-one/connections/connect-networks/private-net#optional-ensure-that-traffic-can-reach-your-network +[remote-managed-tunnel]: https://developers.cloudflare.com/cloudflare-one/connections/connect-apps/install-and-setup/tunnel-guide/#set-up-a-tunnel-remotely-dashboard-setup +[create-remote-managed-tunnel]: https://developers.cloudflare.com/cloudflare-one/connections/connect-apps/install-and-setup/tunnel-guide/#1-create-a-tunnel +[addon-remote-tunnel]: ../docs/remote-tunnel.md +[addon-remote-or-local]: ../docs/tunnels.md diff --git a/cloudflared/config.yaml b/cloudflared/config.yaml index 3f6b1cc..4a26d8d 100644 --- a/cloudflared/config.yaml +++ b/cloudflared/config.yaml @@ -18,8 +18,9 @@ map: name: Cloudflared options: additional_hosts: [] - external_hostname: null + external_hostname: '' tunnel_name: homeassistant + tunnel_token: '' schema: additional_hosts: - disableChunkedEncoding: bool? @@ -28,16 +29,17 @@ schema: catch_all_service: str? custom_config: bool? data_folder: list(config|share|ssl)? - external_hostname: str + external_hostname: str? log_level: list(trace|debug|info|notice|warning|error|fatal)? nginx_proxy_manager: bool? quick_tunnel: bool? reset_cloudflared_files: bool? - tunnel_name: str + tunnel_name: str? + tunnel_token: str? warp_enable: bool? warp_reset: bool? warp_routes: - str? slug: cloudflared url: https://github.com/brenner-tobias/addon-cloudflared/ -version: 1.0.5 +version: 2.0.0 diff --git a/cloudflared/translations/en.yaml b/cloudflared/translations/en.yaml index ee4c3ba..3ba4a1d 100644 --- a/cloudflared/translations/en.yaml +++ b/cloudflared/translations/en.yaml @@ -63,3 +63,8 @@ configuration: description: >- When enabled, the Cloudflare Warp related add-on configuration will be resetted upon next add-on start. + tunnel_token: + name: Cloudflare Tunnel Token + description: >- + When set all other options will be ignored. Use this option if you set up + the tunnel with the Cloudflare Dashboard.