# Using your App with FLECS Core

## Navigating to Your App

1. **Access 'Apps':** Begin by navigating to the 'Apps' section in FLECS Core.

## **Minimized View**

* Hover over items for explanations.
* View key details in a glance:
  * **App Name:** e.g., Node-RED.
  * **App Vendor:** e.g., OpenJS Foundation.
  * **App Version:** e.g., 3.0.2.
* Perform quick actions:
  * **Open App:** Launch in a new tab (editor or configurator).
  * **New Instance:** Create, if multi-instance is supported.
  * **Uninstall:** Remove the app.
  * **More Info:** Access additional information and relevant links.

<figure><img src="/files/vLKIyofZuHeQTmlrxhNe" alt=""><figcaption><p>App minimized view</p></figcaption></figure>

## Expanded View for Detailed Control

Expand your app's section for comprehensive control and information.

### General Information

* Hover over items for explanations.
* **App Name:** e.g., Node-RED.
* **App Vendor:** e.g., OpenJS Foundation.
* **App Version:** e.g., 3.0.2.
* **Status Indicators:**
  * **Green:** Running.
  * **Red:** Stopped.
  * **Yellow:** Issue Detected.
* **Instance Details:**
  * **Name**
  * **Version**

<figure><img src="/files/96LutHTIf0QILPQ4hJzx" alt=""><figcaption><p>App maximized view</p></figcaption></figure>

### Actions and Settings

* **Open App:** Launch in a new tab (editor or configurator).
* **New Instance:** Available for multi-instance apps.
* **Uninstall App:** Remove the app completely.
* **Instance Control:**
  * **Start/Stop:** Manage the app instance.
  * **Settings:** Customize instance configurations.
* **Instance Info:** Access details about Ports, Volumes, Logfile.

<figure><img src="/files/oXuR5Acjv6lhUiTXg4up" alt=""><figcaption><p>Info about app</p></figcaption></figure>

### Settings for Network or Device Access, Environments and Port Mappings

#### **Network Access**

* Enable app access to network interfaces (Layer 2 Ethernet).
* Necessary for fieldbus protocols (EtherCAT, PROFINET).

<figure><img src="/files/rfmbfeQxeKb8Qvhp6L9K" alt=""><figcaption><p>Network and Device settings for an app instance</p></figcaption></figure>

#### **USB Devices**

* Grant access to USB devices, CAN interfaces, etc.
* Common for license dongle access.
* Note: Restart the instance after activating USB devices for recognition.

#### **Environment Variables:**

* Set, edit, or delete environment variables for your app instances.
  * Click 'ADD Environment variable'.
  * Add the Key and Value (e.g., `Key=MyEnv Value=123`).
  * Do not use quotation marks.
  * Save your environment settings before closing.

<figure><img src="/files/3fgDIBhIAmsb3RnWgypq" alt=""><figcaption><p>Set environment variables for your App</p></figcaption></figure>

#### Port Mappings

* Here you can add port mappings to the instance of this app.
  * Click 'ADD PORT MAPPING'
  * Use host:container (e.g., 8081:80 to map the container port 80 to the port 8081 on the host). Do not use quotation marks.
  * Click 'ADD PORT RANGE MAPPING' to select a whole range of ports from Start to End
  * After changing the port mapping, you have to restart the instance in order to apply it.\ <br>

    <figure><img src="/files/NUOpuDtMvP1gQKCGYhsJ" alt=""><figcaption><p>Set port mappings for your App instance</p></figcaption></figure>
* **Automatic Scanning:** FLECS scans and displays all network interfaces and devices.
* **Save Configurations:** Remember to save settings before exiting.

#### Editor Hostname and Path Prefix

Here you can define a custom path prefix for the editor of this app instance.

1. **Select the Path Prefix** you want to use.
2. **Enter your desired name** to create a clear and readable URL.
3. **Save your settings** to apply the changes.

After configuration, you can access the editor either via the fixed default URL or your custom URL based on the chosen path prefix.

<figure><img src="/files/3AgN1pmo2TMkePnLdCAi" alt=""><figcaption><p>Set the Editor hostname for your App instance</p></figcaption></figure>

### Uninstalling an Instance

* **Uninstall Instance:** Remove a specific instance of the app.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.flecs.tech/product-docs/flecs-core/app-management/using-your-app-with-flecs-core.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
