The app_meta.json File
A Portal must know a few things about your app that cannot be configured in the docker-compose.yml.template
file
because they are specific to how Portal treats your app.
This is what the app_meta.json
file is for.
Full Example
This is a complete example of an app_meta.json
file.
Click on the plus buttons for a description of each field.
JSON | |
---|---|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 |
|
- The version of the
app_meta.json
format. Should be "1.1". - The version of your app. This is used to determine if an update is available. It can but does not have to match with your own versioning scheme.
- The name of your app as seen in the URL. It must be unique across all apps in the app store. It can only contain lowercase letters, numbers, and dashes.
- The name of the icon file that you must provide alongside the
app_meta.json
file. It may be a PNG or JPEG or SVG file of any size, but it would be best if it is not huge. - This is where you configure the ports that your app exposes to the internet.
- The
container_name
is the name of the container that you defined in thedocker-compose.yml.template
file. - The
container_port
is the port that your app is listening on inside the container. - The
entrypoint_port
is the port that you want to expose to the internet. It can behttp
(mapped to 443) ormqtt
(mapped to 8883).
- The
- Here you can configure the access control for your app.
It is a mapping of path prefixes to access control settings.
The empty string
""
is the default and will be used for all paths that are not explicitly configured. Read more about access control here. - Most Portal apps do not run continuously but are started on demand and stopped after an idle period. This is where you can configure this behavior. Read more about it here.
- This is the minimum size of a Portal that is required to run your app and should be set according to your app's CPU and memory requirements. If you do not specify this, your app will be available on all Portal sizes.
- This is where you can configure the information that is displayed in the app store. See Submitting to the App Store for more information.
- The name of your app as seen in the app store and below the icon on the Portal home screen.
It can be different from the
name
field and may include uppercase letters and spaces. - (Optional) The URL of the repository where the source code of your app is hosted. Right now, this is only used for automatically checking for updates. It only works with GitHub repositories which use the "Release" feature.
- (Optional) The URL of the homepage of your app. This is where users can find more information about your app.
Schema
To help you write your app_meta.json
file,we publish a JSON schema that describes the format
here.
Add it to your IDE to get auto-completion and validation.
Here is a guide for Visual Studio Code
and one for PyCharm.
Versioning
Since the format of the app_meta.json
evolves over time,
it is important to include the version of the format in which it is written.
It is contained in the v
attribute.
The current version is 1.2
.
When new versions are released, we will attempt to make them backwards compatible. That means that Portal still can process the previous version and translate it to the current one.
Past Updates
Version 1.2
- Added the
homepage
andupstream_repo
fields.
Version 1.1
- Added the
pretty_name
field.