# Clonio CLI

[              Clonio ](index.html)MIT-licensed CLI - privacy-first database cloning

Test with real data. Without the GDPR nightmare.
================================================

Clonio CLI clones production-like database data into development, test, staging, and CI while applying anonymization, schema sync, key remapping, and signed audit logs.

Run it from your terminal, Docker, Composer, or CI pipeline. No external cloud detour. No data leaves your infrastructure.

 [Read the docs](docs/getting-started/introduction.md) [Install the CLI](docs/getting-started/installation.md) 

 

  Dark DevOps run 

 ```
<span class="clonio-prompt">$</span> clonio init
<span class="clonio-prompt">$</span> clonio connection:add production --production
<span class="clonio-prompt">$</span> clonio cloning:dump --connection production
<span class="clonio-prompt">$</span> clonio cloning:run production.cloning.yaml --target ci
<span class="clonio-ok">✓ anonymization rules applied</span>
<span class="clonio-ok">✓ foreign keys remapped</span>
<span class="clonio-ok">✓ audit artefact signed</span>
```

 

                source database    anonymize remap    CI target   

audit artefact signed



 

 

  MIT licensed Runs in your infrastructure Signed audit logs Docker/Composer/CI ready 

 Problem solved

Production-like data without production risk.
---------------------------------------------

Give developers and QA useful database states while keeping personally identifiable values, production identifiers, and run evidence under control.

 ### Realistic data without exposing people

Apply explicit transformations to names, emails, addresses, tokens, identifiers, and payment-related fields before records reach the target environment.

  ### Repeatable .cloning.yaml runs

Generate a cloning file, review it once, commit it, and rerun the same cloning path whenever a team needs fresh production-like data.

  ### Audit evidence teams can keep

Produce signed audit artefacts and structured process logs for local storage, S3-compatible storage, email, Slack, Microsoft Teams, or ntfy.

  

  CLI workflow

Initialize, inspect, clone.
---------------------------

 **Connection names stay separate from secrets.**The generated YAML controls row selection, schema synchronization, anonymization strategies, and key remapping. It is safe to commit because it references connection names, not credentials.

 

  first run 

 ```
<span class="clonio-prompt">$</span> clonio init
<span class="clonio-prompt">$</span> clonio connection:add production --production
<span class="clonio-prompt">$</span> clonio connection:add local-dev
<span class="clonio-prompt">$</span> clonio cloning:dump --connection production
<span class="clonio-prompt">$</span> clonio cloning:run production.cloning.yaml --target local-dev
```

 

 

  Core capabilities

Built for careful database movement.
------------------------------------

 ### Privacy-first transformations

Use fake, hash, mask, null, static, or keep per column, with PII matchers to help draft a configuration you can review.

  ### Schema-aware transfers

Create missing tables, add missing columns, and keep target environments aligned when production schema moves faster.

  ### Key remapping

Replace primary keys with new random values and rewrite foreign keys consistently across cloned records.

  ### DevOps-ready execution

Run from a standalone binary, PHAR, Composer dev dependency, Docker image, local scripts, or CI jobs.

  

  Open source

MIT licensed. Unrestricted usage.
---------------------------------

Use Clonio CLI inside your own infrastructure, including commercial projects. Sponsorships and feature requests help keep development moving.

 

Support the project, request capabilities through the GitHub issue template, or inspect the source before adopting it in your workflow.

 [Sponsor Clonio](https://github.com/sponsors/clonio-dev) [Request a feature](https://github.com/clonio-dev/clonio-cli/issues/new?template=feature_request.md) [View source](https://github.com/clonio-dev/clonio-cli)
