Views: 3678
Last Modified: 18.01.2021
The following data is used for creating a site
- Site name.
- Site type (kernel, ext_kernel or link).
- Site encoding.
- Execution of agents on cron or no execution.
- Additional options for connecting to MySQL (base, login, password) and DOCUMENT_ROOT for site.
What happens inside Bitrix environment when creating a site:
- catalogs necessary for site operation are created.
- database and login with password to connect to it are created.
- cron entries are created.
- apache, nginx configuration files are created.
Launching site via API:
/opt/webdir/bin/bx-sites -a create -s -t kernel
Ansible-playbook:
ansible-playbook /etc/ansible/web.yml -e ansible_playbook_file=/opt/webdir/temp/<TASK_ID>/opts.yml
To delete a site, you need to only specify the delete site catalog.