humanai-web/README.md

46 lines
1.1 KiB
Markdown
Raw Normal View History

# humanAI — landing page
React + Vite static site, served by nginx in the `humanai-landing` Docker container,
behind Nginx Proxy Manager on the `nginxproxymanager_default` network.
## Development
```bash
npm install
npm run dev
```
## Deploy
```bash
./deploy.sh
```
The script builds images locally, pushes them to piha.local via the `piha` Docker context,
and runs smoke tests against the mailer endpoint.
## Mailer
The `mailer/` directory contains a standalone Express microservice that handles the contact
form. It runs as `humanai-mailer` on the same Docker network as NPM so it can be proxied
without exposing any port to the host.
### Manual steps required before first deploy
**(a) Create a Fastmail app-password and write credentials to `mailer.env` on the deploy machine:**
```
# mailer.env (never commit this file)
SMTP_USER=youruser@fastmail.com
SMTP_PASS=your-app-password
```
**(b) In Nginx Proxy Manager → Proxy Host for `gethumanai.pl` → Custom Locations:**
| Field | Value |
|---|---|
| location | `/api` |
| scheme | `http` |
| forward hostname | `humanai-mailer` |
| port | `3000` |