A traditional application package includes the following parts:
{service-name}-{version}.tar.gz—.tar.gz file that packages the software and its supporting components.
Script files—Shell script files.
install.sh—Script file for installing the application.
start.sh—Script file for staring the application.
stop.sh—Script file for stopping the application.
uninstall.sh—Script file for uninstalling the application.
upgrade.sh—Script file for upgrading the application.
param.yaml—Application parameter file. User can edit and save application metadata information, such as the application name, type, package name, access port, and service parameters, in this file.
"name": "apache-tomcat", # Application name
"type": "software", # Application type
"app_file": "apache-tomcat-9.0.0.M21.tar.gz", # Application package name
"endpoint": { # API port. The value can be a fixed value or a built-in function. Currently, the “$get_var_from_config()” function is supported, which obtains variables automatically from the customized_config parameter.
"port": 8080,
"protocol": "TCP"
},
"customized_config": { # Customized parameter settings. The parameters can be edited during application deployment and finally deployed to the host as environment variables.
"tomcat_port": {
"type": "string",
"default": "8080",
"description": "tomcat port"
},
"install_dir":{
"type": "string",
"default": "/data/tomcat",
"description": "The directory where tomcat will be installed in"
}
}