move dev scripts to tools/, migrate to bws, use example.com in docs
Provision server / provision (push) Successful in 7s

- Move new-app.sh, new-service.sh, remove-app.sh from scripts/ to tools/
- Migrate new-app.sh and remove-app.sh from bw to bws
- Replace real domains with example.com in documentation and help text
This commit is contained in:
2026-03-19 11:10:14 -04:00
parent 5a8d9a8aa0
commit 037b78734f
8 changed files with 127 additions and 109 deletions
+12 -10
View File
@@ -10,9 +10,9 @@ scripts, nginx configs, and Gitea Actions workflows for each app.
docker/
nginx/ # Reverse proxy (nginx:alpine) + SSL config
nginx.conf # Main nginx config
conf.d/ # Per-app server blocks (e.g. timothykim.net.conf)
conf.d/ # Per-app server blocks (e.g. example.com.conf)
compose.yml
timothykim.net/ # timothykim.net static site
<domain>/ # Per-app static site (e.g. example.com)
compose.yml
garage/ # Garage S3-compatible object storage
compose.yml
@@ -21,8 +21,10 @@ scripts/
bootstrap.sh # First-time server setup (manual, uses Bitwarden)
configure.sh # Idempotent server config (CI-safe)
deploy.sh # Deploy + cert issuance + provision (called via SSH)
new-app.sh # Scaffolding script to add a new static site
new-service.sh # Scaffolding script to add a new Docker service
tools/
new-app.sh # Add a new static site (run from dev machine)
new-service.sh # Add a new Docker service (run from dev machine)
remove-app.sh # Remove a static site (run from dev machine)
.gitea/workflows/ # Per-app deploy workflows triggered by path changes
```
@@ -59,19 +61,19 @@ bash /opt/hantim/scripts/bootstrap.sh
## Adding a new app
```bash
./scripts/new-app.sh <domain>
./tools/new-app.sh <domain>
```
Example: `./scripts/new-app.sh hcsuzuki.net`
Example: `./tools/new-app.sh example.com`
This single command handles everything: creates DNS records on Vultr, creates
the Gitea repo from `static-site-template`, generates all config files, issues
the SSL cert (zero downtime), commits and pushes, triggers the first build,
and verifies the site is live.
**Prerequisites:** domain nameservers pointed to Vultr, `bw`/`jq`/`dig`
installed. Uses the deploy SSH key from Bitwarden -- no personal server
access needed. See USECASES.md for full details.
**Prerequisites:** domain nameservers pointed to Vultr, `bws`/`jq`/`dig`
installed. Uses the deploy SSH key from Bitwarden Secrets Manager -- no
personal server access needed. See USECASES.md for full details.
After the site is live, clone the app repo and customize it:
@@ -84,7 +86,7 @@ git add . && git commit -m "initial content" && git push
## Deploying changes
**App code change** (push to an app repo like `timothykim.net`):
**App code change** (push to an app repo like `example.com`):
- The app's `build.yml` builds the Docker image, pushes to the registry, and
SSHes into the server to trigger a deploy