diff --git a/DEPLOYMENT-GUIDE.md b/DEPLOYMENT-GUIDE.md index 43e85f0..e27c199 100644 --- a/DEPLOYMENT-GUIDE.md +++ b/DEPLOYMENT-GUIDE.md @@ -3,6 +3,7 @@ ## Overview This setup builds the web-app **locally** with machine-specific configuration, then deploys the built artifacts to each target machine. Each machine gets its own customized build with: + - Machine-specific `.env` files - Machine-specific images in the `public` folder @@ -47,6 +48,7 @@ nix-build ./build-local.nix -A all && ./result/bin/build-all ``` This: + 1. Copies web-app source to `./build/{machine}/` 2. Copies machine-specific `.env` file 3. Copies machine-specific images to `public/` @@ -79,19 +81,24 @@ nix-build ./krops.nix -A all && ./result ## Customization -### Add a new machine: +### Add a new machine + 1. Create directories: `machine-specific/machine3/env/` and `machine-specific/machine3/images/` 2. Add `.env` file and images for machine3 3. Create `config/machine3/configuration.nix` 4. Add machine3 to `build-local.nix` and `krops.nix` -### Update environment variables: +### Update environment variables + Edit `.env` in `machine-specific/{machine-name}/env/.env`, then rebuild locally -### Update images: +### Update images + Replace files in `machine-specific/{machine-name}/images/`, then rebuild locally -### Update web-app code: +### Update web-app code + Edit files in `web-app/`, then rebuild locally -After any changes: rebuild locally, then redeploy. \ No newline at end of file +After any changes: rebuild locally, then redeploy. +