Deployment scripts for self-hosted infrastructure. Pairs with infra (private) for configuration.
infra/services/<name>/.env → automa/services/<name>/deploy.sh
infra (private) holds config templates and .env.example files — the "what" and "how to configure".
automa (public) holds deployment scripts — the "how to deploy". Zero hardcoded values, zero domain names.
Workflow:
- Clone infra (private), fill in
.envfiles for each service you want - Clone automa (public), run the matching deploy script
- Each script reads
INFRA_DIRto locate the corresponding.env
# Example
cd infra/services/email && cp .env.example .env && $EDITOR .env
cd automa/services/email
INFRA_DIR=../../infra/services/email ./deploy.shThis project embraces Unix principles:
- Modularity: Each service is self-contained
- Simplicity: Minimal dependencies, clear configuration
- Composability: Tools work together through standard interfaces
- Transparency: Plain text configuration, readable scripts
System services deployed from infra module configs.
Postfix + Dovecot + OpenDKIM + SpamAssassin.
INFRA_DIR=/path/to/infra/services/email ./services/email/deploy.shWeb server and reverse proxy vhosts.
INFRA_DIR=/path/to/infra/services/nginx ./services/nginx/deploy.shGFW-resistant proxy.
# Server (VPS)
INFRA_DIR=/path/to/infra/services/shadowsocks/server ./services/shadowsocks/server/deploy.sh
# Client (home machine)
INFRA_DIR=/path/to/infra/services/shadowsocks/client ./services/shadowsocks/client/deploy.shReverse tunnel — expose home services through VPS.
# Server (VPS)
INFRA_DIR=/path/to/infra/services/frp/server ./services/frp/server/deploy.sh
# Client (home machine)
INFRA_DIR=/path/to/infra/services/frp/client ./services/frp/client/deploy.shDocker-based services with their own config.
Automated Minecraft Fabric server deployment with mod management.
Location: minecraft/
Quick Start:
cd minecraft
cp .env.example .env # Edit as needed
docker compose up -dSee minecraft/README.md for details.
Voice communication server with minimal configuration.
Location: teamspeak/
Quick Start:
cd teamspeak
cp .env.example .env # Edit as needed
docker compose up -dSee teamspeak/README.md for details.
Self-hosted file sync and collaboration platform.
Location: nextcloud/
Quick Start:
cd nextcloud
cp .env.example .env # Edit as needed
docker compose up -dSee nextcloud/README.md for details.
Batch clone all repositories from a GitHub organization.
Location: bin/org-clone.sh
Usage:
./bin/org-clone.sh <org-name>- Docker & Docker Compose
- Bash 4.0+
- Git
automa/
├── bin/ # Utility scripts
│ └── lib/common.sh # Shared logging + env helpers
├── services/ # Infrastructure deploy scripts (reads infra .env)
│ ├── email/deploy.sh
│ ├── nginx/deploy.sh
│ ├── shadowsocks/
│ │ ├── server/deploy.sh
│ │ └── client/deploy.sh
│ └── frp/
│ ├── server/deploy.sh
│ └── client/deploy.sh
├── minecraft/ # Minecraft server (Docker)
├── teamspeak/ # TeamSpeak server (Docker)
├── nextcloud/ # Nextcloud (Docker)
└── README.md
All services follow consistent patterns:
cd <service-name>
docker compose up -dcd <service-name>
docker compose logs -fcd <service-name>
docker compose downcd <service-name>
docker compose pull
docker compose up -d- Always change default passwords in
.envfiles - Keep
.envfiles out of version control - Use strong passwords for production deployments
- Review exposed ports before deployment
Contributions welcome. Keep changes:
- Simple and focused
- Well-documented
- Following existing patterns
- Unix philosophy aligned
MIT License - See LICENSE file for details.