Embedded Jetty Webserver on a fixed Port

I’m running metadata on a MAC.
Every time i start it i can notice on the logs
“metabase.server Launching Embedded Jetty Webserver with config: {:port 13972}”
The port used is changing on every restart. Any way to set this to a fixed port?

THanks

{
“browser-info”: {
“language”: “en-gb”,
“platform”: “MacIntel”,
“userAgent”: “Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/605.1.15 (KHTML, like Gecko)”,
“vendor”: “Apple Computer, Inc.”
},
“system-info”: {
“file.encoding”: “UTF-8”,
“java.runtime.name”: “OpenJDK Runtime Environment”,
“java.runtime.version”: “11.0.7+9-202002041938”,
“java.vendor”: “AdoptOpenJDK”,
“java.vendor.url”: “https://adoptopenjdk.net/”,
“java.version”: “11.0.7”,
“java.vm.name”: “OpenJDK 64-Bit Server VM”,
“java.vm.version”: “11.0.7+9-202002041938”,
“os.name”: “Mac OS X”,
“os.version”: “10.15.6”,
“user.language”: “en”,
“user.timezone”: “Europe/Lisbon”
},
“metabase-info”: {
“databases”: [
“postgres”
],
“hosting-env”: “osx”,
“application-database”: “h2”,
“application-database-details”: {
“database”: {
“name”: “H2”,
“version”: “1.4.197 (2018-03-18)”
},
“jdbc-driver”: {
“name”: “H2 JDBC Driver”,
“version”: “1.4.197 (2018-03-18)”
}
},
“run-mode”: “prod”,
“version”: {
“date”: “2020-09-15”,
“tag”: “v0.36.6”,
“branch”: “release-0.36.x”,
“hash”: “cb258fb”
},
“settings”: {
“report-timezone”: “Europe/London”
}
}
}

Hi @epenedos
I don’t know if the Mac App picks up the environment variable, but you can try setting that and then launching the Mac App again:

MB_JETTY_PORT=3123

I would recommend that you use the JAR instead of the Mac App.