We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 943c90b commit e5857eeCopy full SHA for e5857ee
hack/test-port-forwarding.pl
@@ -25,6 +25,12 @@
25
my $ipv4 = inet_ntoa(scalar gethostbyname(hostname())) or die;
26
my $ipv6 = ""; # todo
27
28
+# macOS Github runners seem to use "localhost" as the hostname
29
+if ($ipv4 eq "127.0.0.1" && $Config{osname} eq "darwin") {
30
+ $ipv4 = qx(system_profiler SPNetworkDataType -json | jq -r 'first(.SPNetworkDataType[] | select(.ip_address) | .ip_address) | first');
31
+ chomp $ipv4;
32
+}
33
+
34
# If $instance is a filename, add our portForwards to it to enable testing
35
if (-f $instance) {
36
open(my $fh, "+< $instance") or die "Can't open $instance for read/write: $!";
0 commit comments