Deploy
The deployment process as documented here is currently under the direct management of the ComUnity Team. This content is intended to provide insights into the development process and serve as a reference. The ability for developers to handle deployment autonomously is a feature that is coming soon.
The deployment of applications within the ComUnity Developer Toolkit is managed via a powerful script referred to as the config agent. The config agent script is a crucial tool for automating the deployment process in the ComUnity Developer Toolkit. It provides a structured and configurable approach to manage the complex array of tasks involved in deploying applications, from database operations to web server management and beyond. With this tool, developers can create repeatable and reliable deployment processes, minimising the potential for human error and increasing efficiency. Below is a simplified example of such a script, which provides the foundation for the various deployment actions.
This script illustrates a deployment step involving the execution of an SQL command. Here's a breakdown of deployment actions that the config agent can orchestrate:
Deployment Actions
1. SQL Command Execution (type: sql_command_url
)
type: sql_command_url
)Purpose: Executes SQL scripts to manage database states.
Parameters:
sql_url
: Endpoint for the SQL script.db_connection
: Database connection string.rollback_sql_url
: Endpoint for rollback script.
2. File Download (type: download
)
type: download
)Purpose: Retrieves files from specified URLs for local use.
Parameters:
url
: File source URL.path
: Destination path for downloaded files.
3. Web Deployment (type: webdeploy
)
type: webdeploy
)Purpose: Deploys web packages to an IIS server.
Parameters:
url
: Location of the web deployment package.
4. Command Execution (type: command
)
type: command
)Purpose: Runs command-line operations, often following file downloads.
Parameters:
timeout_in_seconds
,exe_path
,command_line
,current_directory
.
5. Folder Management (type: folder_delete
)
type: folder_delete
)Purpose: Removes directories from the server.
Parameters:
folder_path
: Target path for deletion.
6. IIS Application Pool and Website Management
Purpose: Controls the state of IIS app pools and websites, including starting, stopping, and deleting.
Parameters:
Common parameters include
name
,retry
.
7. Synchronization of Data Settings (type: synch_data_settings
)
type: synch_data_settings
)Purpose: Aligns data settings post SDK updates.
Parameters:
deployment_code
,retry
.
8. HTTP Resource Interaction (type: http_request
)
type: http_request
)Purpose: Manages HTTP requests for various deployment needs.
Parameters:
headers
,verb
,url
,body
,retry
.
9. IIS Virtual Directory Management
Purpose: Handles the creation, deletion, and updates of IIS virtual directories.
Parameters:
name
,physical_path
,rollback_physical_path
,retry
.
10. Service Control (type: service_start
, type: service_stop
)
type: service_start
, type: service_stop
)Purpose: Manages the state of Windows Services.
Parameters:
name
.
11. Work In Progress Site Management (type: wip_start
, type: wip_stop
)
type: wip_start
, type: wip_stop
)Purpose: Facilitates the setup of temporary sites during deployment.
Parameters:
name
,domain
,cert_subject_name
,path
.
12. SSL Certificate Management
Purpose: Manages the installation and cleanup of SSL/TLS certificates.
Parameters:
Related to certificate management, including
timeout_millis
,domain
,retry
,cert_store
,challenge_url
,validation
.
Each step is highly configurable with flags such as optional
and always_run
to determine the criticality and frequency of the operation. These parameters help ensure that deployments can be highly customised to suit the needs of different environments and deployment scenarios.