remove new-app.sh, update docs to reference app.sh directly

This commit is contained in:
2026-03-20 20:14:16 -04:00
parent 787e747fa4
commit 43fc8c2e7b
5 changed files with 9 additions and 23 deletions
+1 -1
View File
@@ -161,7 +161,7 @@ Client -> nginx (443) -> /media/ location -> garage:3902
runs envsubst at container start. Values come from `.env` generated by the
`.env.keys` mechanism.
**Bucket setup** (done by `new-app.sh` via admin API v2):
**Bucket setup** (done by `app.sh` via admin API v2):
1. `POST /v2/CreateBucket` with `globalAlias: <domain>`
2. `POST /v2/AllowBucketKey` to grant media-key read/write access
3. `POST /v2/UpdateBucket` to enable website access
-1
View File
@@ -9,7 +9,6 @@ for technical deep-dives, USECASES.md for expected behaviors.
- `scripts/configure.sh` -- Idempotent server config (firewall, certbot, start services; CI-safe)
- `scripts/deploy.sh` -- SSH-triggered deploy + cert issuance + provision (deploy-*, cert-*, provision commands)
- `tools/app.sh` -- App provisioning by subcommand (dns, repo, files, cert, garage, build, verify, all)
- `tools/new-app.sh` -- Wrapper for `app.sh all` (backwards compat)
- `tools/new-service.sh` -- Scaffold a new Docker Compose service (compose + workflow)
- `tools/remove-app.sh` -- Remove a static site (local files + Gitea repo)
- `docker/nginx/conf.d/` -- Per-app nginx server blocks
+7 -7
View File
@@ -28,7 +28,7 @@ scripts/
configure.sh # Idempotent server config (CI-safe)
deploy.sh # Deploy + provision (called via SSH)
tools/
new-app.sh # Add a new static site (run from dev machine)
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)
docker/
@@ -73,7 +73,7 @@ server. Everything is idempotent.
## Adding a new static site
```bash
./tools/new-app.sh <domain>
./tools/app.sh all <domain>
```
This single command handles everything: DNS records (Vultr), Gitea repo
@@ -186,13 +186,13 @@ Project: `hantim`. Fetched via `bws` CLI on the server.
|---|---|---|
| `hantim-ci-registry-push` | Gitea token for Docker registry | `bootstrap.sh` |
| `hantim-deploy-ssh-public-key` | Deploy user's SSH public key | `bootstrap.sh` |
| `hantim-deploy-ssh-private-key` | Deploy user's SSH private key | `new-app.sh` |
| `hantim-new-app-script` | Gitea API token for creating repos | `new-app.sh` |
| `hantim-vultr-api-key` | Vultr API key for DNS management | `new-app.sh` |
| `hantim-deploy-ssh-private-key` | Deploy user's SSH private key | `app.sh` |
| `hantim-new-app-script` | Gitea API token for creating repos | `app.sh` |
| `hantim-vultr-api-key` | Vultr API key for DNS management | `app.sh` |
| `hantim-garage-rpc-secret` | Garage cluster RPC secret | `deploy.sh` |
| `hantim-garage-argento-node-id` | Argento's Garage node ID + address | `deploy.sh` |
| `hantim-garage-admin-token` | Garage admin API token | `deploy.sh`, `new-app.sh` |
| `hantim-garage-media-key-id` | S3 access key ID for media uploads | `new-app.sh`, `aws` CLI |
| `hantim-garage-admin-token` | Garage admin API token | `deploy.sh`, `app.sh` |
| `hantim-garage-media-key-id` | S3 access key ID for media uploads | `app.sh`, `aws` CLI |
| `hantim-garage-media-secret-key` | S3 secret key for media uploads | `aws` CLI |
Machine accounts: `hantim-server` (token at `/etc/bws-token`), `hantim-ci` (reserved).
+1 -1
View File
@@ -38,7 +38,7 @@ for stateless static sites.
## 3. Add a new static site
**Trigger:** `./tools/new-app.sh example.com` from dev machine.
**Trigger:** `./tools/app.sh all example.com` from dev machine.
**Prerequisites:** domain nameservers on Vultr, `bws`/`jq`/`dig` installed.
-13
View File
@@ -1,13 +0,0 @@
#!/bin/bash
set -euo pipefail
# Thin wrapper — delegates to app.sh all
if [ -z "${1:-}" ]; then
echo "Usage: ./tools/new-app.sh <domain>"
echo " Example: ./tools/new-app.sh example.com"
echo ""
echo "For individual steps, use: ./tools/app.sh <command> <domain>"
exit 1
fi
exec "$(dirname "$0")/app.sh" all "$1"