- Update README, AGENTS.md, docs/index.md, docs/deployment/cd.md, docs/services/forgejo.md: replace deploy-rs with Comin everywhere - Fix repo URL references (cryodev-server -> cryodev) - Fix forgejo admin create command to use shell alias - Rewrite cd.md for Comin-only deployment
100 lines
2.7 KiB
Markdown
100 lines
2.7 KiB
Markdown
# cryodev NixOS Configuration
|
|
|
|
Declarative NixOS infrastructure for the **cryodev** environment, managed with Nix Flakes.
|
|
|
|
## Quick Start
|
|
|
|
```bash
|
|
# Clone repository
|
|
git clone https://git.cryodev.xyz/steffen/cryodev.git
|
|
cd cryodev
|
|
|
|
# Check configuration
|
|
nix flake check
|
|
|
|
# Build a host
|
|
nix build .#nixosConfigurations.cryodev-main.config.system.build.toplevel
|
|
```
|
|
|
|
## Hosts
|
|
|
|
| Host | Architecture | Deployment | Description |
|
|
|------|--------------|------------|-------------|
|
|
| `cryodev-main` | x86_64 | Pull (Comin) | Main server |
|
|
| `cryodev-pi` | aarch64 | Pull (Comin) | Raspberry Pi client |
|
|
|
|
## Services
|
|
|
|
| Service | Domain | Description |
|
|
|---------|--------|-------------|
|
|
| Headscale | `headscale.cryodev.xyz` | Self-hosted Tailscale server |
|
|
| Headplane | `headplane.cryodev.xyz` | Headscale web UI |
|
|
| Forgejo | `git.cryodev.xyz` | Git hosting with CI/CD |
|
|
| Netdata | `netdata.cryodev.xyz` | Monitoring dashboard |
|
|
| Mail | `mail.cryodev.xyz` | Email (Postfix/Dovecot) |
|
|
|
|
## Raspberry Pi SD Images
|
|
|
|
SD card images for Raspberry Pi clients are **built automatically** on every push to `main`.
|
|
|
|
Download from: [Releases](https://git.cryodev.xyz/steffen/cryodev/releases)
|
|
|
|
```bash
|
|
# Flash to SD card
|
|
zstd -d cryodev-pi-sd-image.img.zst
|
|
sudo dd if=cryodev-pi-sd-image.img of=/dev/sdX bs=4M status=progress
|
|
```
|
|
|
|
See [Adding a new Raspberry Pi](docs/getting-started/new-client.md) for the full workflow.
|
|
|
|
## Documentation
|
|
|
|
Full documentation is available in the [`docs/`](docs/index.md) directory:
|
|
|
|
- [Prerequisites](docs/getting-started/prerequisites.md)
|
|
- [New Raspberry Pi Client](docs/getting-started/new-client.md)
|
|
- [SD Image Reference](docs/getting-started/sd-image.md)
|
|
- [Server Installation](docs/getting-started/first-install.md)
|
|
- [Reinstallation](docs/getting-started/reinstall.md)
|
|
- [Services](docs/services/)
|
|
- [Deployment](docs/deployment/cd.md)
|
|
|
|
## Directory Structure
|
|
|
|
```
|
|
.
|
|
├── flake.nix # Flake entry point
|
|
├── constants.nix # Central configuration
|
|
├── hosts/ # Host configurations
|
|
├── modules/ # Reusable NixOS modules
|
|
├── pkgs/ # Custom packages
|
|
├── overlays/ # Nixpkgs overlays
|
|
├── templates/ # Host templates
|
|
├── scripts/ # Helper scripts
|
|
├── apps/ # Nix apps (rebuild)
|
|
├── lib/ # Helper functions
|
|
└── docs/ # Documentation
|
|
```
|
|
|
|
## Commands
|
|
|
|
```bash
|
|
# Format code
|
|
nix fmt
|
|
|
|
# Run checks
|
|
nix flake check
|
|
|
|
# Update dependencies
|
|
nix flake update
|
|
|
|
# Enter dev shell
|
|
nix develop
|
|
|
|
# Build Pi SD image locally
|
|
nix build .#nixosConfigurations.cryodev-pi.config.system.build.sdImage
|
|
```
|
|
|
|
## License
|
|
|
|
Private repository.
|