Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 13 additions & 10 deletions content/en/docs/deployment/on-premises-design/ms-windows/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ Before starting this how-to, make sure you have the following prerequisites:

* Suitable database servers are MariaDB, MS SQL Server, MySQL, Oracle Database and PostgreSQL. See [System Requirements](/refguide/system-requirements/#databases) for more information

* A local or domain user with the *“log on as a service”* local security policy set
* A local user, domain user or group managed service account (gMSA) with the *“log on as a service”* local security policy set

## Installing the Mendix Service Console {#service-console}

Expand Down Expand Up @@ -88,32 +88,35 @@ To deploy a Mendix app using the Mendix Service Console, follow these steps:
* **Display name** – the description of the app which is visible as a tooltip for the app in the left bar of the Mendix Service Console or as a column in the list of Windows services
* **Description** – a description of the application that will be visible in the Mendix Service Console
* **Startup type** – select whether you want the app to be started automatically when the server starts, started with a delay, started manually, or disabled altogether
* **User name** and **Password** – the app will always run under the user account given here, and the service will be installed with this user account configured (for more information, see [Prerequisites](#Prerequisites))
* **User name** and **Password** – the app will run under the user account given here, and the service will be installed with this user account configured (for more information, see [Prerequisites](#Prerequisites))
* **Install service with LocalSystem account** – optionally, select the checkbox if you want to use a gMSA account for a Mendix app instead of the user account given under **User name** and **Password**.

4. Click **Next >**.

4. Click **Next >**.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is the '>' removed? It's part of the text on the button.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I cannot resolve this comment, unfortunately. But it's resolved in my eyes.

5. Optionally, if you selected the **Install service with LocalSystem account** checkbox while creating the app, install the service once your app is created. The service will be installed with the LocalSystem account. (You can verify the service account type in the Services app of Windows.) Execute the command below in the administrator command prompt to change the account type to your gMSA: `sc.exe config MyServiceName obj= "YOURDOMAIN\MyGMSAAccount$"`

{{< figure src="/attachments/deployment/on-premises-design/ms-windows/18580728.png" >}}
{{< figure src="/attachments/deployment/on-premises-design/ms-windows/gmsa.png" >}}

5. On the **Project Files** screen, click **Select app…**.
6. On the **Project Files** screen, click **Select app…**.

{{< figure src="/attachments/deployment/on-premises-design/ms-windows/service_console_selectapp.png" >}}

6. Now select the **MDA** file that was [created in Mendix Studio Pro](/refguide/create-deployment-package-dialog/) and contains your application logic. After the installation of your MDA file, you will see which Mendix server (Mendix Runtime) version is needed.
7. Now select the **MDA** file that was [created in Mendix Studio Pro](/refguide/create-deployment-package-dialog/) and contains your application logic. After the installation of your MDA file, you will see which Mendix server (Mendix Runtime) version is needed.

7. Configure the **Database Settings**:
8. Configure the **Database Settings**:

* **Type** – the database server type
* **Host** – the IP address or host name of the database server
* **Name** – the database name
* **User name** and **Password** – the database user name and password

8. Click **Next >**.
9. Click **Next >**.

{{< figure src="/attachments/deployment/on-premises-design/ms-windows/18580726.png" >}}

9. On the **Common Configuration** screen, keep the default settings. These settings should only be changed if this is needed for your application setup.
10. On the **Common Configuration** screen, keep the default settings. These settings should only be changed if this is needed for your application setup.

10. Click **Finish** and start the application.
11. Click **Finish** and start the application.

## Configuring the Microsoft Internet Information Services Server{#configure-msiis}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,48 @@ $appName = 'Name of Mendix app'
Install-MxService $appName
```

### Sample Script - Set App Runtime Settings

The following script example demonstrates how to set runtime settings for your app. It applies custom runtime configuration settings to your application using a hashtable of key-value pairs.

```text
$appName = 'Name of Mendix app'
$settings = @{
'MaxJavaHeapSize' = '2048'
'DatabaseHost' = 'localhost'
}

# Set runtime settings
Set-MxAppRuntimeSettings $appName -Settings $settings
```

### Sample Script - Set App Constant

The following script example demonstrates how to set an application constant for your app. It updates a specific constant value in your Mendix app configuration.

```text
$appName = '{Name of your app}'
$constants = @{
'constantName' = 'constantValue'
'constantName2' = 'constantValue2'
}

# Set application constant
Set-MxAppConstants $appName -Constants $constants
```

### Sample Script - Get Server Id

The `Start-MxApp` cmdlet automatically retrieves the Server ID (License ID) when starting a Mendix app. You can use this unique identifier for license tracking and application monitoring. The following script example demonstrates the process required to retrieve Server Id.

```text
# Start the Mendix app and get Server ID
$app = Start-MxApp "MyAppName" -NoService -SynchronizeDatabase

# Display the Server ID
Write-Host "Server ID: $($app.ServerId)"
```

## Troubleshooting

If you encounter any issues while automating Mendix deployment on Windows using cmdlets, use the following troubleshooting tips to help you solve them.
Expand Down
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.