diff --git a/runtime/lib/resolve-nextcloud-target.php b/runtime/lib/resolve-nextcloud-target.php new file mode 100644 index 0000000..52b4d1b --- /dev/null +++ b/runtime/lib/resolve-nextcloud-target.php @@ -0,0 +1,24 @@ +#!/usr/bin/env php +'); + $url = rtrim(trim((string)$argv[1]), '/'); + bratonien_tools_nc_transport_scheme($url); + $host = bratonien_tools_nc_transport_host($url); + echo bratonien_tools_nc_transport_public_ip($host)."\n"; + exit(0); +} +catch (Throwable $e) +{ + fwrite(STDERR, $e->getMessage()."\n"); + exit(1); +}