You can run MDriven Server and MDriven Turnkey directly on macOS for local testing when you have the native macOS packages and a compatible .NET runtime.
This page covers a temporary, native Terminal-based run: both processes remain running only while their Terminal sessions remain open. For a persistent macOS deployment with launchd, use HowTos:Deploying on MacOs. For a container-based local environment, use Documentation:Running MDriven Locally with Docker.
Choose the deployment approach
| Approach | Use it when | Guide |
|---|---|---|
| Native macOS processes | You want to run the downloaded MDriven Server and Turnkey packages directly with .NET during local testing. | This page |
| Native macOS services | You want MDriven Server and Turnkey to start and run as macOS services. | HowTos:Deploying on MacOs |
| Docker containers | You want an isolated, reproducible local environment on Intel/AMD or Apple Silicon hardware. | Documentation:Running MDriven Locally with Docker |
What runs where
MDriven Server hosts the server-side model and is the endpoint that MDriven Turnkey connects to. Turnkey provides the web application interface. In this local example, both applications run on the same Mac.
| Component | Local address in this guide | Purpose |
|---|---|---|
| MDriven Server | http://localhost:5010
|
Runs the MDriven Server process. |
| MDriven Turnkey | http://localhost:5011
|
Runs the Turnkey web application and connects to the local MDriven Server. |
If you change either port, update the matching startup argument and configuration so that Turnkey still points to the MDriven Server endpoint.
Prerequisites
Before installing the MDriven packages, prepare the Mac:
- macOS Ventura or later is recommended.
- You need access to the Terminal application.
- Download packages that match your Mac processor architecture: x64 for Intel Macs and ARM64 for Apple Silicon Macs.
- Install .NET SDK 8.0. The installed runtime must be compatible with the MDriven package you download.
- Obtain the current native MDriven Server package and MDriven Turnkey package from the MDriven download location available to you.
Check the processor architecture
Open Terminal and run:
uname -m
Use the result to select the appropriate package architecture. For example, an Apple Silicon Mac requires an ARM64 package; using an AMD64/x64 package can prevent the application from starting.
Install Homebrew
Homebrew is a macOS package manager. Skip this section if brew is already installed.
- Open Terminal.
- Install Homebrew:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
- Verify that Terminal can find Homebrew:
brew --version
The command should return a Homebrew version number.
Verify the installation:
$ brew --version
Install and verify .NET 8
- Install the .NET 8 SDK:
brew install --cask dotnet-sdk@8
- Verify the installation:
dotnet --list-runtimes
Confirm that the output includes a .NET 8 runtime. If dotnet is not found after installation, resolve the .NET command-path issue before continuing. Documentation:Deployment: Two Ways To Install Docker Desktop on MacOS Intel includes an example of linking the .NET command on Intel macOS.
Download and prepare MDriven Server
- Download the current native MDriven Server package for your processor architecture.
- Create a working directory. For example:
mkdir -p ~/MDrivenServer
- Extract the downloaded package into
~/MDrivenServer. - In Terminal, move to the extracted directory:
cd ~/MDrivenServer
Use this command to download the package:
- Download and Unzip the latest MDriven Server package into your ~/Downloads directory:
$ curl -s "https://mdriven.net/Rest/ProductRelease/Get?vProduct=ServerCore&platform=linux" | jq -r '.Releases[0]'
https://downloads.mdriven.net/releases/MDrivenServerCoreLinux_20251030.zip
$ wget https://downloads.mdriven.net/releases/MDrivenServerCoreLinux_20251030.zip
$ unzip MDrivenServerCoreLinux.zip -d ~/MDrivenServer
Remove the macOS quarantine attribute
macOS Gatekeeper can apply a quarantine attribute to files extracted from downloaded archives. If Gatekeeper prevents the MDriven binaries from running, remove the attribute from the extracted MDriven Server directory:
xattr -r -d com.apple.quarantine ~/MDrivenServer
Run this command only for a package you obtained from a trusted MDriven download source.
Run this command for MDriven Server:
$ sudo xattr -r -d com.apple.quarantine ~/MDrivenServer
Run this command for MDriven Turnkey: Remove the quarantine flag from the Turnkey binaries
$ sudo xattr -r -d com.apple.quarantine ~/MDrivenTurnkey
Start MDriven Server
Start the server using the executable entry point supplied in the downloaded package. Configure it to listen on port 5010 and disable HTTPS for this local HTTP example.
Keep this Terminal window open. A successful startup reports that the server is listening on port 5010.
If the package does not start, first confirm that:
- You downloaded the package for the correct processor architecture.
- .NET 8 is installed and available as
dotnet. - The quarantine attribute was removed when Gatekeeper blocked execution.
- Port
5010is not already in use.
Use this command to start the server:
$ dotnet ~/Downloads/MDrivenServer/AppCompleteGenericCore.dll -port=5010 --nohttps
Expected Output:
Configure Server startup options in CommandLineOverride.xml:
cat CommandLineOverride.xml
<root>
<arg>port=5010</arg> // only when you run locally
<arg>nohttps</arg> // remove to have https
<arg>host=localhost</arg> // only when you run locally
<!-- <arg>iis=https://localhost/TKDebug</arg> // probably the only param you send for IIS hosting -->
</root>%
Download and prepare MDriven Turnkey
- Download the current native MDriven Turnkey package for the same processor architecture.
- Create a separate working directory. For example:
mkdir -p ~/MDrivenTurnkey
- Extract the Turnkey package into
~/MDrivenTurnkey. - Remove the macOS quarantine attribute if required:
xattr -r -d com.apple.quarantine ~/MDrivenTurnkey
- Open a second Terminal window and move to the extracted Turnkey directory:
cd ~/MDrivenTurnkey
Use this command to download the package:
$ curl -s "https://mdriven.net/Rest/ProductRelease/Get?vProduct=TurnkeyCore&platform=linux" | jq -r '.Releases[0]'
https://downloads.mdriven.net/releases/MDrivenTurnkeyCoreLinux_20251030.zip
$ wget https://downloads.mdriven.net/releases/MDrivenTurnkeyCoreLinux_20251030.zip
$ unzip MDrivenTurnkeyCoreLinux_20251030.zip -d ~/MDrivenTurnkey
Expected Result if server started successfully.
Configure the Turnkey-to-server connection
Turnkey must know where to find MDriven Server. When both applications run on the same Mac using this guide's ports, the target is localhost on port 5010.
Review these locations under the Turnkey installation directory before starting Turnkey:
| Location | Role |
|---|---|
App_Data/MDrivenServerOverride.xml
|
Contains the MDriven Server host or domain and port that Turnkey uses. For this local setup, use localhost and the MDriven Server port.
|
App_Data/TurnkeySettings.xml
|
Holds Turnkey settings. |
App_Data/turnkey-settings/
|
May contain HardServerUrl.xml, which can affect the server URL used by Turnkey.
|
Do not assume that changing only the startup port changes the Turnkey connection target. If you move MDriven Server from port 5010, update the applicable Turnkey configuration file as well.
For the settings and credentials required when configuring Turnkey for an on-premise installation, see Documentation:Set up MDriven Turnkey on premise.
Configure Turnkey startup options in CommandLineOverride.xml: $ App_Data %
$ cat CommandLineOverride.xml
<root>
<arg>port=5011</arg> // only when you run locally (You can change ports from here)
<arg>nohttps</arg> // remove to have https
<arg>host=localhost</arg> // only when you run locally
<!-- <arg>iis=https://localhost/TKDebug</arg> // probably the only param you send for IIS hosting -->
</root>
MDrivenServerOverride.xml (Contains details for the MDriven server that the Turnkey will be connecting to such as IP/Domain name if any and port). In this example we are running both MDriven Server and Turnkey locally thus "localhost".
Configure the Server connection in MDrivenServerOverride.xml:
$ cat MDrivenServerOverride.xml
<?xml version="1.0" encoding="utf-8"?>
<root>
<MDrivenServerOverride MDrivenServerUser="a" MDrivenServerPWD="123456">http://localhost:5010/</MDrivenServerOverride>
</root>
Alternative configuration using HardServerUrl.xml: HardServerUrl.xml
<?xml version="1.0" encoding="utf-8"?>
<root HardServerUrl="http://localhost:5010">
</root>
Start MDriven Turnkey
Start Turnkey using the executable entry point supplied in the downloaded package. Configure its local HTTP endpoint on port 5011.
Keep the second Terminal window open. The startup output should confirm that Turnkey started and identified the MDriven Server URL. If it cannot connect, verify that MDriven Server is still running on localhost:5010 and review the Turnkey configuration files described above.
Expected output when starting Turnkey:
Expected OutCome:
$ dotnet StreaminAppCoreWebApp.dll --nohttps
This is MDriven Turnkey, 2025-10-28 05:13
Leave this window open to keep the server running
http://localhost:5011
useIIS: False
autoblazer is always on - use SysMDrivenMiscSettingsSingleton.GlobalBlazorClient
Started with MDrivenServerUrl: http://localhost:5010/
info: Microsoft.AspNetCore.DataProtection.KeyManagement.XmlKeyManager[62]
User profile is available. Using '/Users/saged-lyd-govnet-services/.aspnet/DataProtection-Keys' as key repository; keys will not be encrypted at rest.
info: Microsoft.Hosting.Lifetime[14]
Now listening on: http://localhost:5011
info: Microsoft.Hosting.Lifetime[0]
Application started. Press Ctrl+C to shut down.
info: Microsoft.Hosting.Lifetime[0]
Hosting environment: Development
info: Microsoft.Hosting.Lifetime[0]
Content root path: /Users/saged-lyd-govnet-services/Desktop/ScreenShots/MDrivenTurnkeyCoreOsxX64_20251028
info: Microsoft.AspNetCore.Hosting.Diagnostics[1]
Request starting HTTP/1.1 GET http://localhost:5011/ - - -
CHANGEDOWNLOADLOC looking for dir :/Users/saged-lyd-govnet-services/Desktop/ScreenShots/MDrivenTurnkeyCoreOsxX64_20251028/wwwroot/_framework
CHANGEDOWNLOADLOC Dir found - we are published
info: Microsoft.AspNetCore.Routing.EndpointMiddleware[0]
Executing endpoint 'TurnkeyWebAppGeneric.Controllers.TurnkeyController.Index (StreaminAppCoreWebApp)'
info: Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker[102]
Route matched with {action = "Index", controller = "Turnkey", page = "", area = ""}. Executing controller action with signature Microsoft.AspNetCore.Mvc.ActionResult Index() on controller TurnkeyWebAppGeneric.Controllers.TurnkeyController (StreaminAppCoreWebApp).
info: Microsoft.AspNetCore.Mvc.RedirectToActionResult[1]
Executing RedirectResult, redirecting to /App/StartUpView?redirectUrl=%252f.
Use this command to start Turnkey: Bash
$ dotnet ~/MDrivenTurnkey/StreaminAppCoreWebApp.dll
Expected Output: The output will confirm the application started and successfully recognized the Server URL:
Expected output when startup is successful:
This is MDriven Turnkey, 2025-10-20 17:52
Leave this window open to keep the server running
http://localhost:5011...
Started with MDrivenServerUrl: http://localhost:5010/...Now listening on: http://localhost:5020
Verify the installation
- In a browser, open
http://localhost:5010to verify that MDriven Server responds. - In a browser, open
http://localhost:5011to verify that Turnkey responds. - You can also test the endpoints from Terminal:
curl http://localhost:5010
curl http://localhost:5011
A responding Turnkey process does not by itself prove that an application model is available. Upload a model before using the Turnkey application as an end-to-end test. Without a model, the Turnkey page can continue loading even though the Turnkey process started successfully.
Troubleshooting
A port is already in use
MDriven Server or Turnkey cannot start if another process already uses its assigned port. Use a different port in the application's startup configuration, then update the corresponding connection configuration. For example, changing the MDriven Server port requires a matching update to the Turnkey server URL override.
Turnkey starts but cannot reach MDriven Server
Check these items in order:
- Confirm that the MDriven Server Terminal window is still running.
- Open
http://localhost:5010in a browser or usecurl. - Check
App_Data/MDrivenServerOverride.xmlfor the expected host and port. - Check whether
HardServerUrl.xmlunderApp_Data/turnkey-settings/specifies a different server URL.
The application stops when Terminal closes
This is expected for the temporary process-based setup. Keep both Terminal windows open while testing. To run the applications after logout or restart, create macOS services as described in HowTos:Deploying on MacOs.
Gatekeeper blocks an application
Remove the quarantine attribute from the relevant extracted package directory with xattr -r -d com.apple.quarantine, then start the application again. Do not remove quarantine attributes from files whose origin you cannot verify.
Next steps
- Configure a persistent native installation with HowTos:Deploying on MacOs.
- Learn the deployment choices in Documentation:Deployment.
- Use Documentation:Running MDriven Locally with Docker if you prefer Docker Compose and container isolation.
- Install and run the modeling client on a supported platform; see Documentation:Installing MDriven Designer on MacOs for the current macOS findings.
