Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can the Xamarin Mac Agent's port be configured? (to something other than port 22)

Tags:

xamarin

I'm configuring my network's firewall to permit connecting to my Mac build server when I'm away from my house. I would like to set up port forwarding to send traffic to the Mac via an alternative to port 22.

Can the Xamarin Mac Agent be configured to listen on a port other than 22? Does Visual Studio permit connecting to the Mac Agent on a port other than 22?

like image 842
Steve McKisic Avatar asked Oct 26 '25 10:10

Steve McKisic


1 Answers

It seems that Zagaeski’s solution stopped working on new VS/Xamarin versions... I am using a different approach here; on my Windows machine, I have created a port forwarding rule, like this:

netsh interface portproxy add v4tov4 listenport=22 listenaddress=127.0.0.1 connectport=REMOTE_PORT connectaddress=REMOTE_HOST_OR_IP_ADDRESS

CMD

In my case, REMOTE_PORT is 17352 and REMOTE_HOST_OR_IP_ADDRESS is the hostname (DNS name or IP Address) of the remote network I am connecting to.

This way I am able to connect my Visual Studio / Xamarim to the host “127.0.0.1”, on port 22 (internally redirected to my remote host/port):

VS

Hope it helps.

like image 173
Daniel Brilho Avatar answered Oct 29 '25 07:10

Daniel Brilho



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!