# Configuration

> Describe your environment with config
---

**Pigsty treats Infra & Database as Code.** You can describe everything with declarative config [**Inventory**](/docs/config/inventory).
Which is usually an [**Ansible Inventory**](https://docs.ansible.com/ansible/latest/inventory_guide/intro_inventory.html) in YAML format: `pigsty.yml`.
But [CMDB](/docs/config/cmdb) can also be used as dynamic inventory.

The [`configure`](/docs/config/configure) procedure will generate a config according to your environment and input.
But it's **OPTIONAL**: you can always edit the `pigsty.yml` file directly as [**tutorial**](/docs/config/tutorial) shows.
And there are plenty of [**templates**](/docs/config/template) for your reference.



**Inventory**


        The main config file of Pigsty, Describe your entire deployment



**Configure**


        Generate config file according to your input & environment



**Tutorial**


        Planning your deployment according to business requirements



**Template**


        Available configuration templates and examples



**Security**


        Security considerations and best practices for prod deployment



**CMDB**


        Use PostgreSQL as CMDB instead of local YAML config file







--------


**PGSQL**


        PostgreSQL Cluster with HA, PITR, IaC, ACL, Monitoring, Pooling



**INFRA**


        Nginx, Repo, DNS, NTP, Prometheus and Grafana stack for Observability



**NODE**


        Enroll nodes into the desired state and monitor it, and VIP, HAProxy



**ETCD**


        Reliable distributed consensus storage (DCS), empowering PGSQL HA



**MINIO**


        S3 compatible object storage, optional backup storage



**REDIS**


        High-performance in-memory cache, optional data structure server





| [<span class="text-sky-600 font-bold">PGSQL</span>](/docs/pgsql/param) | [<span class="text-green-700 font-bold">INFRA</span>](/docs/infra/param) |  [<span class="text-amber-500 font-bold">NODE</span>](/docs/node/param)   |   [<span class="text-sky-400 font-bold">ETCD</span>](/docs/etcd/param)    |
|:----------------------------------------------------------------------------:|:------------------------------------------------------------------------------:|:-------------------------------------------------------------------------------:|:-------------------------------------------------------------------------------:|
| [<span class="text-red-800 font-bold">MINIO</span>](/docs/minio/param) |  [<span class="text-red-400 font-bold">REDIS</span>](/docs/redis/param)  | [<span class="text-blue-500 font-bold">DOCKER</span>](/docs/docker/param) | [<span class="text-gray-500 font-bold">FERRET</span>](/docs/ferret/param) |

---

Section pages:

- [Inventory](/docs/config/inventory/): The main config file for Pigsty
- [Configure](/docs/config/configure/): how to configure pigsty inventory file?
- [Tutorial](/docs/config/tutorial/): Forge a complex config from scratch
- [Template](/docs/config/template/): Configuration templates for Pigsty
- [Security](/docs/config/security/): Security considerations and best-practices
- [CMDB](/docs/config/cmdb/): Use PostgreSQL as config inventory
