test_apps/config_app_ynh/config_panel.toml

238 lines
6.2 KiB
TOML
Raw Normal View History

2021-09-02 02:31:39 +02:00
version = "1.0"
2021-08-14 12:26:20 +02:00
[main]
name = "Main panel"
2021-09-02 02:31:39 +02:00
services = ["nginx"]
2021-09-06 16:28:53 +02:00
2021-08-14 12:26:20 +02:00
[main.components]
2021-09-06 16:28:53 +02:00
name = "Classic fields"
2021-08-14 12:26:20 +02:00
[main.components.boolean]
2021-09-06 16:28:53 +02:00
ask = "I can haz boolean?"
2021-08-14 12:26:20 +02:00
type = "boolean"
[main.components.number]
2021-09-06 16:28:53 +02:00
ask = "I can haz number?"
2021-08-14 12:26:20 +02:00
type = "number"
min = 1
max = 100
[main.components.range]
2021-09-06 16:28:53 +02:00
ask = "I can haz range?"
2021-08-14 12:26:20 +02:00
type = "range"
2021-09-02 02:31:39 +02:00
min = 0
2021-08-14 12:26:20 +02:00
max = 100
2021-09-02 02:31:39 +02:00
step = 10
2021-08-14 12:26:20 +02:00
[main.components.str]
2021-09-06 16:28:53 +02:00
ask = "I can haz string?"
2021-08-14 12:26:20 +02:00
type = "string"
[main.components.text]
2021-09-06 16:28:53 +02:00
ask = "I can haz text?"
2021-08-14 12:26:20 +02:00
type = "text"
[main.components.password]
2021-09-06 16:28:53 +02:00
ask = "I can haz paszwurd?"
2021-08-14 12:26:20 +02:00
type = "password"
[main.components.path]
2021-09-06 16:28:53 +02:00
ask = "I can haz path?"
2021-08-14 12:26:20 +02:00
type = "path"
[main.components.email]
2021-09-06 16:28:53 +02:00
ask = "I can haz email?"
2021-08-14 12:26:20 +02:00
type = "email"
[main.components.url]
2021-09-06 16:28:53 +02:00
ask = "I can haz url?"
2021-08-14 12:26:20 +02:00
type = "url"
[main.components.date]
2021-09-06 16:28:53 +02:00
ask = "I can haz date?"
2021-08-14 12:26:20 +02:00
type = "date"
[main.components.time]
2021-09-06 16:28:53 +02:00
ask = "I can haz time?"
2021-08-14 12:26:20 +02:00
type = "time"
[main.components.color]
2021-09-06 16:28:53 +02:00
ask = "I can haz color?"
2021-08-14 12:26:20 +02:00
type = "color"
[main.components.select]
2021-09-06 16:28:53 +02:00
ask = "I can chose option?"
2021-08-14 12:26:20 +02:00
type = "select"
2021-09-02 02:31:39 +02:00
choices.option1 = "Plop1"
choices.option2 = "Plop2"
choices.option3 = "Plop3"
2021-08-14 12:26:20 +02:00
[main.components.domain]
2021-09-06 16:28:53 +02:00
ask = "I can haz domain?"
2021-08-14 12:26:20 +02:00
type = "domain"
[main.components.user]
2021-09-06 16:28:53 +02:00
ask = "I can haz user?"
2021-08-14 12:26:20 +02:00
type = "user"
[main.components.tags]
2021-09-06 16:28:53 +02:00
ask = "I can haz several emailz?"
2021-08-14 12:26:20 +02:00
type = "tags"
2021-09-02 02:31:39 +02:00
placeholder = "Enter some emails separated by commas"
limit = 3
pattern.regexp = '^.+@.+$'
pattern.error = 'An email is required for this field'
2021-08-14 12:26:20 +02:00
2021-09-02 02:31:39 +02:00
[main.components.tags2]
2021-09-06 16:28:53 +02:00
ask = "I can chose several tagz?"
2021-09-02 02:31:39 +02:00
type = "tags"
choices = ['table', 'chair', 'bed', 'desk']
placeholder = "Add some tags"
icon = "bed"
[main.components.file]
2021-09-06 16:28:53 +02:00
ask = "I can haz file?"
2021-09-02 02:31:39 +02:00
type = "file"
2021-08-14 12:26:20 +02:00
[main.messages]
2021-09-06 16:28:53 +02:00
name = "Messages / Read-only components"
2021-08-14 12:26:20 +02:00
[main.messages.success]
2021-09-06 16:28:53 +02:00
ask = "I can haz success"
2021-09-02 02:31:39 +02:00
type = "alert"
style = "success"
icon = "beer"
2021-08-14 12:26:20 +02:00
[main.messages.info]
2021-09-06 16:28:53 +02:00
ask = "I can haz info"
2021-09-02 02:31:39 +02:00
type = "alert"
style = "info"
2021-08-14 12:26:20 +02:00
[main.messages.warning]
2021-09-06 16:28:53 +02:00
ask = "Onoez i haz a warnin'"
2021-09-02 02:31:39 +02:00
type = "alert"
style = "warning"
2021-08-14 12:26:20 +02:00
[main.messages.danger]
2021-09-06 16:28:53 +02:00
ask = "Onoez i haz a Danger!!"
2021-09-02 02:31:39 +02:00
type = "alert"
style = "danger"
2021-08-14 12:26:20 +02:00
[main.messages.display_text]
2021-09-06 16:28:53 +02:00
ask = "I haz a simple text"
2021-08-14 12:26:20 +02:00
type = "display_text"
[main.messages.markdown]
2021-09-06 16:28:53 +02:00
ask = "I haz some **awesome** *markdown* text!!"
2021-08-14 12:26:20 +02:00
type = "markdown"
[main.generic]
name = "Generic options"
2021-09-02 02:31:39 +02:00
[main.generic.pattern]
ask = "This is a question with a pattern validation"
2021-08-14 12:26:20 +02:00
type = "string"
2021-09-02 02:31:39 +02:00
pattern.regexp = '^[A-F]\d\d$'
pattern.error = "Provide a room like F12 : one uppercase and 2 numbers"
2021-08-14 12:26:20 +02:00
[main.generic.example]
ask = "This is a question with an example value"
type = "string"
example = "Camille"
[main.generic.required]
ask = "This is a required value"
2021-08-14 12:26:20 +02:00
type = "string"
optional = false
2021-08-14 12:26:20 +02:00
[main.generic.help]
ask = "Here we add some help"
2021-09-02 02:31:39 +02:00
type = "select"
2021-09-06 16:28:53 +02:00
help = "You can not fill this question with your keyboard (yes i know it's very useful)"
2021-09-02 02:31:39 +02:00
choices.question = "Display next question"
choices.section = "Display next section"
[main.generic.visible]
2021-09-06 16:28:53 +02:00
ask = "This question is only displayed if previous question is set to 'Display next question'"
2021-09-02 02:31:39 +02:00
type = "string"
visible = "help == 'question'"
2021-09-02 02:31:39 +02:00
[main.ifsection]
2021-09-06 16:28:53 +02:00
name = "This section is only displayed if the previous question is set to 'Display next section'"
visible = "help == 'section'"
2021-09-02 02:31:39 +02:00
[main.ifsection.sub]
2021-09-06 16:28:53 +02:00
ask = "I can haz cheezburgers?"
2021-08-14 12:26:20 +02:00
type = "string"
[bind]
name = "Bind panel"
2021-08-14 12:26:20 +02:00
[bind.settings]
2021-09-06 16:28:53 +02:00
name = "Bind to settings"
2021-08-14 12:26:20 +02:00
[bind.settings.arg1]
2021-08-14 12:26:20 +02:00
ask = "Save app settings arg1"
type = "string"
[bind.variable]
2021-09-06 16:28:53 +02:00
name = "Bind to key/value in files"
2021-08-14 12:26:20 +02:00
[bind.variable.arg2]
2021-09-06 16:28:53 +02:00
ask = "I can haz value for arg2 in test.yml ?"
2021-08-14 12:26:20 +02:00
type = "string"
bind = ":__FINALPATH__/test.yml"
2021-08-14 12:26:20 +02:00
[bind.variable.arg3]
2021-09-06 16:28:53 +02:00
ask = "I can haz value for arg3 in test.json ?"
2021-08-14 12:26:20 +02:00
type = "string"
bind = ":__FINALPATH__/test.json"
2021-08-14 12:26:20 +02:00
[bind.variable.arg4]
2021-09-06 16:28:53 +02:00
ask = "I can haz value for arg4 in test.ini ?"
2021-08-14 12:26:20 +02:00
type = "string"
bind = ":__FINALPATH__/test.ini"
2021-08-14 12:26:20 +02:00
[bind.variable.arg5]
2021-09-06 16:28:53 +02:00
ask = "I can haz value for arg5 in test.php ?"
2021-08-14 12:26:20 +02:00
type = "string"
bind = ":__FINALPATH__/test.php"
2021-08-14 12:26:20 +02:00
[bind.variable.arg6]
2021-09-06 16:28:53 +02:00
ask = "I can haz value for arg6 in test.py ?"
2021-08-14 12:26:20 +02:00
type = "string"
bind = ":__FINALPATH__/test.py"
2021-08-14 12:26:20 +02:00
[bind.file]
2021-09-06 16:28:53 +02:00
name = "Bind to an entire file"
2021-09-02 02:31:39 +02:00
[bind.file.arg7]
2021-09-06 16:28:53 +02:00
ask = "I can haz a .cube ?"
2021-09-02 02:31:39 +02:00
type = "file"
accept = ".cube"
bind = "__FINALPATH__/test.cube"
2021-09-02 02:31:39 +02:00
[bind.file.arg7b]
2021-09-06 16:28:53 +02:00
ask = "Emeged i can edit sum file!#1!"
2021-09-02 02:31:39 +02:00
type = "text"
bind = "__FINALPATH__/nginx.conf"
2021-08-14 12:26:20 +02:00
[bind.function]
2021-09-06 16:28:53 +02:00
name = "Custom bash getters / validators / setters"
2021-08-14 12:26:20 +02:00
[bind.function.arg8]
2021-09-02 02:31:39 +02:00
ask = "Custom validator and setter for arg8 password"
2021-08-14 12:26:20 +02:00
type = "password"
bind = "null"
2021-09-02 02:31:39 +02:00
[bind.function.arg9]
2021-09-02 02:31:39 +02:00
ask = "Custom getter arg9"
type = "markdown"
bind = "null"
2021-09-02 02:31:39 +02:00
[bind.function.alert]
2021-09-02 02:31:39 +02:00
ask = "Custom getter alert"
type = "alert"
style = "info"
bind = "null"