Module Management
Use this guide for daily INFRA administration. It covers installation, removal, scaling, and component maintenance.
Install INFRA Module
Use the infra.yml playbook to install the INFRA module on the infra group:
Uninstall INFRA Module
Use the infra-rm.yml playbook to uninstall the INFRA module from the infra group:
This playbook has no deletion safeguard. Full execution removes infra_data, nginx_data, nginx_home (default: /www), and /var/lib/grafana.
If you only need to stop services or deregister targets, use -t service or -t deregister. Read the complete removal scope and back up required data before running it.
Scale Out INFRA Module
Assign infra_seq to new nodes and add them to the infra group in the inventory:
Use the -l limit option to execute the playbook on the new node only:
Manage Local Repository
Local repository management tasks:
Complete subtask list:
Manage Nginx
Nginx management tasks:
Request HTTPS certificate:
Manage Infrastructure Components
Management commands for various infrastructure components:
Common maintenance commands:
Manage Grafana Anonymous Access
Grafana permits anonymous Viewer access by default. To require login, edit /etc/grafana/grafana.ini on each target Infra node and set enabled = false under [auth.anonymous]:
Restart Grafana to apply the change:
Rerunning ./infra.yml -t grafana_config renders /etc/grafana/grafana.ini from the control node’s roles/infra/templates/grafana/grafana.ini.j2 and overwrites manual edits. To retain the change, update that local template or reapply it after the configuration task. This setting is independent of grafana_auth_proxy and controls only Grafana’s own anonymous access.
Manage Grafana Passwords
Grafana uses two password parameters. grafana_admin_password defaults to the public value pigsty. grafana_view_password defaults to DBUser.Viewer.
| Parameter | Rendered configuration |
|---|---|
grafana_admin_password | /etc/grafana/grafana.ini and /infra/env/pigsty |
grafana_view_password | /etc/grafana/provisioning/datasources/pigsty.yml |
Change the public defaults before production. After initialization, a change to grafana_admin_password in the inventory does not reset the live Grafana account password. Change it through Grafana or a supported administration interface. Keep the inventory consistent and regenerate the environment when needed:
grafana_view_password is the password used by the default PostgreSQL metadb data source as dbuser_view. If the database role password changes, update grafana_view_password, render the datasource configuration, and restart Grafana. A change on only one side breaks the dashboard connection. This is not a visitor login password.
Was this page helpful?
Thanks—your feedback helps us improve this page.
What got in the way? (optional)