================================================
FILE: docs/admin/05.get_started/02.why_should_you_not_host_yourself.mdx
================================================
---
title: Why should you (not?) host yourself?
hide_table_of_contents: true
description: " "
hide_title: true
---
## Why should you host yourself?
- **You believe in a free, open and decentralized internet.** In a centralized internet, private companies and government can spy, analyze and influence people by dictating how they connect with each other, and by filtering content. YunoHost is developed by a community who believe in an open and decentralized internet, and we hope that you do, too!
- **You want to have control of your data and services.** Your pictures, chat messages, browsing history, and that text you are writing for school, have nothing to do on somebody else's server (a.k.a. The Cloud). They are part of your private life, but also part of your family's life, your friend's life, and so on. These data should be managed by *you*, not a random company in the US who wants your data to analyze them and sell the results.
- **You want to learn about how computers and the Internet work.** Operating your own server is a pretty good context to understand the basic mechanisms at the heart of operating systems and the Internet. You might have to deal with command line interface, network architecture, DNS configuration, SSH, and so on.
- **You want to explore new possibilities and customize things.** Ever dreamed of running a Minecraft server for you friends, or a persistent IRC or XMPP client? With your very own server, you can manually install and run virtually any program you want, and customize every bit.
## Why should you *not* host yourself?
- **Self-hosting requires some work and patience.** Hosting yourself is a bit like growing your own garden or vegetables: it requires work and patience. While YunoHost aims to do all the hard work for you, self-hosting still requires that you take time to learn and configure a few things to setup your server properly. You will also need to perform maintenance tasks (such as upgrades) from time to time, or to ask for support if some things break.
- **With great servers comes great responsibilities.** Operating a server means that you are responsible for the data you are hosting. Nobody will be able to recover them for you if they get lost. YunoHost provides backup features, which you should use regularly to backup the configurations and data you care about. You should also keep an eye on security news and recommendations so that your server or critical data don't get compromised.
- **Quality and performance probably won't be as good as premium services.** YunoHost (and most of the applications packaged for it) are free and open-source software, developed by communities of people in their free time and on the basis of best effort. There is no absolute guarantee that software will work in every possible circumstance. The performance of your self-hosted server is also related to its CPU and RAM, and to the available internet connectivity.
================================================
FILE: docs/admin/05.get_started/05.methods.mdx
================================================
---
title: Choose your self-hosting mode
hide_table_of_contents: true
---
You can host yourself at home (on a small computer), or on a remote server. Each solution has its pros and cons:
## At home, for instance on an ARM board or an old computer
You can host yourself at home with an ARM board or a re-purposed regular computer, connected to your home router/box.
- **Pros**: you will have physical control of the machine and only need to buy the hardware;
- **Cons**: you will have to [manually configure your internet box](/admin/get_started/post_install/port_forwarding) and [might be limited by your ISP](/admin/get_started/providers/isp/).
## At home, behind a VPN
A VPN is an encrypted tunnel between two machines. In practice, it makes it "as if" you were directly, locally, connected to your server machine, but actually from somewhere else on the Internet. This allows you to still host yourself at home, while bypassing possible limitations of your ISP. See also [the Internet Cube project](https://internetcu.be/) and [the FFDN](https://www.ffdn.org/).
- **Pros**: you will have physical control of the machine, and the VPN hides your traffic from your ISP and allows you to bypass its limitations;
- **Cons**: you will have to pay a monthly subscription for the VPN.
## On a remote server (VPS or dedicated server)
You can rent a virtual private server or a dedicated machine from [associative](https://db.ffdn.org/) or [commercial](/admin/get_started/providers/servers) "Cloud" providers.
- **Pros**: your server and its internet connectivity will be fast;
- **Cons**: you will have to pay a monthly subscription and won't have physical control of your server.
## Summary
export const styleNone = {
textAlign: 'center',
};
export const styleGood = {
textAlign: 'center',
backgroundColor: 'green',
color: 'white',
};
export const styleMeh = {
textAlign: 'center',
backgroundColor: 'darkgoldenrod',
color: 'white',
};
export const styleDanger = {
textAlign: 'center',
backgroundColor: 'brown',
color: 'white',
};
| At home (e.g. ARM board, old computer) |
At home behind a VPN |
On a remote server (VPS or dedicated) |
|
|---|---|---|---|
| Hardware cost | About 50€ (e.g. a Raspberry Pi) |
None | |
| Monthly cost | Negligible (electricity) |
Around 5€ (VPN) |
Starting at ~3€ (VPS) |
| Physical control of the machine | Yes | Yes | No |
| Manual port routing required | Yes | No | No |
| Possible ISP limitations | Yes (see here) |
Bypassed by VPN | Typically no |
| Internet connectivity | Depends on home connectivity | Typically pretty good | |
- Enter your domain name in the "Server" field, fill the "Security" and "Port" fields as per the IMAP row in the table above, then enter your password in the "Password" field and click "Next"
- Again, your domain name in the "Server" field, but fill the "Security" and "Port" fields as per the SMTP row in the table above, then enter your password in the "Password" field and click "Next"
This is coupled to the 'sources' resource in the manifest.toml
### SourcesThese allow to install specific version of the technology required to run some apps
## DatabasesThis is coupled to the 'database' resource in the manifest.toml - at least for mysql/postgresql. Mongodb/redis may have better integration in the future.
### MysqlThis is coupled to the 'sources' resource in the manifest.toml
### SourcesThis is coupled to the 'database' resource in the manifest.toml - at least for mysql/postgresql. Mongodb/redis may have better integration in the future.
### MysqlSome conditional HTML code here !
{{/if}}` - For internationalized strings, use `y18n.t('some-string-code')` in the JavaScript, or `{{t 'some-string-code'}}` in the HTML template, and put your string in `locales/en.json`. Don't edit other locales files, this will be done using [Weblate](https://translate.yunohost.org/)! ================================================ FILE: docs/dev/80.core/forms.mdx ================================================ --- title: Technical details for config panel structure and form option types --- Doc auto-generated by [this script](https://github.com/YunoHost/doc/blob/da78370c098ca04b590e18fb1c8924242367703e/scripts/forms_doc_generate.py) on 09/01/2026 (YunoHost version 12.1.39) ## Glossary You may encounter some named types which are used for simplicity. - `Translation`: a translated property - used for properties: `ask`, `help` and `Pattern.error` - a `dict` with locales as keys and translations as values: ```toml ask.en = "The text in english" ask.fr = "Le texte en français" ``` It is not currently possible for translators to translate those string in weblate. - a single `str` for a single english default string ```toml help = "The text in english" ``` - `JSExpression`: a `str` JS expression to be evaluated to `true` or `false`: - used for properties: `visible` and `enabled` - operators availables: `==`, `!=`, `>`, `>=`, `<`, `<=`, `!`, `&&`, `||`, `+`, `-`, `*`, `/`, `%` and `match()` - `Binding`: bind a value to a file/property/variable/getter/setter/validator - save the value in `settings.yaml` when not defined - nothing at all with `"null"` - a custom getter/setter/validator with `"null"` + a function starting with `get__`, `set__`, `validate__` in `scripts/config` - a variable/property in a file with `:__FINALPATH__/my_file.php` - a whole file with `__FINALPATH__/my_file.php` - `Pattern`: a `dict` with a regex to match the value against and an error message ```toml pattern.regexp = '^[A-F]\d\d$' pattern.error = "Provide a room number such as F12: one uppercase and 2 numbers" # or with translated error pattern.error.en = "Provide a room number such as F12: one uppercase and 2 numbers" pattern.error.fr = "Entrez un numéro de salle comme F12: une lettre majuscule et deux chiffres." ``` - IMPORTANT: your `pattern.regexp` should be between simple quote, not double. ## Configuration panel structure ### ConfigPanel This is the 'root' level of the config panel toml file #### Examples ```toml version = 1.0 [config] # …refer to Panels doc ``` #### Properties - `version`: `float` (default: `1.0`), version that the config panel supports in terms of features. - `i18n` (optional): `str`, an i18n property that let you internationalize options text. - However this feature is only available in core configuration panel (like `yunohost domain config`), prefer the use `Translation` in `name`, `help`, etc. --- ### Panel Panels are, basically, sections grouped together. Panels are `dict`s defined inside a ConfigPanel file and require a unique id (in the below example, the id is `main`). Keep in mind that this id will be used in CLI to refer to the panel, so choose something short and meaningfull. #### Examples ```toml [main] name.en = "Main configuration" name.fr = "Configuration principale" help = "" services = ["__APP__", "nginx"] [main.customization] # …refer to Sections doc ``` #### Properties - `name`: `Translation` or `str`, displayed as the panel title - `help` (optional): `Translation` or `str`, text to display before the first section - `services` (optional): `list` of services names to `reload-or-restart` when any option's value contained in the panel changes - `"__APP__` will refer to the app instance name - `actions`: FIXME not sure what this does --- ### Section Sections are, basically, options grouped together. Sections are `dict`s defined inside a Panel and require a unique id (in the below example, the id is `customization` prepended by the panel's id `main`). Keep in mind that this combined id will be used in CLI to refer to the section, so choose something short and meaningfull. Also make sure to not make a typo in the panel id, which would implicitly create an other entire panel. If at least one `button` is present it then become an action section. Options in action sections are not considered settings and therefor are not saved, they are more like parameters that exists only during the execution of an action. FIXME i'm not sure we have this in code. #### Examples ```toml [main] [main.customization] name.en = "Advanced configuration" name.fr = "Configuration avancée" help = "Every form items in this section are not saved." services = ["__APP__", "nginx"] [main.customization.option_id] type = "string" # …refer to Options doc ``` #### Properties - `name` (optional): `Translation` or `str`, displayed as the section's title if any - `help`: `Translation` or `str`, text to display before the first option - `services` (optional): `list` of services names to `reload-or-restart` when any option's value contained in the section changes - `"__APP__` will refer to the app instance name - `optional`: `bool` (default: `true`), set the default `optional` prop of all Options in the section - `visible`: `bool` or `JSExpression` (default: `true`), allow to conditionally display a section depending on user's answers to previous questions. - Be careful that the `visible` property should only refer to **previous** options's value. Hence, it should not make sense to have a `visible` property on the very first section. --- ## List of all option types ### Common properties Options are fields declaration that renders as form items, button, alert or text in the web-admin and printed or prompted in CLI. They are used in app manifests to declare the before installation form and in config panels. [Have a look at the app config panel doc](/dev/packaging/advanced/config_panels) for details about Panels and Sections. ! IMPORTANT: as for Panels and Sections you have to choose an id, but this one should be unique in all this document, even if the question is in an other panel. #### Example ```toml [section.my_option_id] type = "string" # ask as `str` ask = "The text in english" # ask as `dict` ask.en = "The text in english" ask.fr = "Le texte en français" # advanced props visible = "my_other_option_id != 'success'" readonly = true # much advanced: config panel only? bind = "null" ``` #### Properties - `type`: the actual type of the option, such as 'markdown', 'password', 'number', 'email', ... - `ask`: `Translation` (default to the option's `id` if not defined): - text to display as the option's label for inputs or text to display for readonly options - in config panels, questions are displayed on the left side and therefore have not much space to be rendered. Therefore, it is better to use a short question, and use the `help` property to provide additional details if necessary. - `visible` (optional): `bool` or `JSExpression` (default: `true`) - define if the option is diplayed/asked - if `false` and used alongside `readonly = true`, you get a context only value that can still be used in `JSExpression`s - `readonly` (optional): `bool` (default: `false`, forced to `true` for readonly types): - If `true` for input types: forbid mutation of its value - `bind` (optional): `Binding`, config panels only! A powerful feature that let you configure how and where the setting will be read, validated and written - if not specified, the value will be read/written in the app `settings.yml` - if `"null"`: - the value will not be stored at all (can still be used in context evaluations) - if in `scripts/config` there's a function named: - `get__my_option_id`: the value will be gathered from this custom getter - `set__my_option_id`: the value will be passed to this custom setter where you can do whatever you want with the value - `validate__my_option_id`: the value will be passed to this custom validator before any custom setter - if `bind` is a file path: - if the path starts with `:`, the value be saved as its id's variable/property counterpart - this only works for first level variables/properties and simple types (no array) - else the value will be stored as the whole content of the file - you can use `__FINALPATH__` or `__INSTALL_DIR__` in your path to point to dynamic install paths - FIXME are other global variables accessible? - [refer to `bind` doc for explaination and examples](/dev/packaging/advanced/config_panels#the-bind-statement) --- ### Common inputs properties Rest of the option types available are considered `inputs`. #### Example ```toml [section.my_option_id] type = "string" # …any common props… + optional = false redact = false default = "some default string" help = "You can enter almost anything!" example = "an example string" placeholder = "write something…" ``` #### Properties - [common properties](#common-properties) - `optional`: `bool` (default: `false`, but `true` in config panels) - `redact`: `bool` (default: `false`), to redact the value in the logs when the value contain private information - `default`: depends on `type`, the default value to assign to the option - in case of readonly values, you can use this `default` to assign a value (or return a dynamic `default` from a custom getter) - `help` (optional): `Translation`, to display a short help message in cli and web-admin - `example` (optional): `str`, to display an example value in web-admin only - `placeholder` (optional): `str`, shown in the web-admin fields only --- ### `markdown` (readonly) Display markdown multi-line content. Markdown is currently only rendered in the web-admin #### Example ```toml [section.my_option_id] type = "display_text" ask = "Text **rendered** in markdown." ``` #### Properties - [common properties](#common-properties) --- ### `alert` (readonly) Alerts displays a important message with a level of severity. You can use markdown in `ask` but will only be rendered in the web-admin. #### Example ```toml [section.my_option_id] type = "alert" ask = "The configuration seems to be manually modified..." style = "warning" icon = "warning" ``` #### Properties - [common properties](#common-properties) - `style`: any of `"success|info|warning|danger"` (default: `"info"`) - `icon` (optional): any icon name from [Fork Awesome](https://forkaweso.me/Fork-Awesome/icons/) - Currently only displayed in the web-admin --- ### `button` (readonly) Triggers actions. Available only in config panels. Renders as a `button` in the web-admin and can be called with `yunohost [app|domain|settings] action run