76 lines
1.9 KiB
Markdown
76 lines
1.9 KiB
Markdown
# humanAI landing page
|
|
|
|
Static bilingual landing page for **humanAI** (gethumanai.com).
|
|
Stack: Astro 6, static output, i18n PL (default `/`) + EN (`/en/`), nginx in Docker.
|
|
|
|
---
|
|
|
|
## Local development
|
|
|
|
```sh
|
|
# Host: SATURN
|
|
npm install
|
|
npm run dev # dev server at http://localhost:4321
|
|
npm run build # build to ./dist/
|
|
npm run preview # preview built site at http://localhost:4321
|
|
```
|
|
|
|
## Docker local test
|
|
|
|
```sh
|
|
# Host: SATURN
|
|
# Create a local test network if npm_proxy doesn't exist locally
|
|
docker network create npm_proxy 2>/dev/null || true
|
|
docker compose up --build
|
|
# site at http://localhost:80
|
|
```
|
|
|
|
## Deploy to VPS
|
|
|
|
```sh
|
|
# Host: SATURN
|
|
./deploy.sh
|
|
```
|
|
|
|
The script:
|
|
1. Commits any pending changes and pushes to Forgejo (`oskar/gethumanai-landing`).
|
|
2. SSH-es to `ubuntu-4gb-hel1-1`, clones/pulls to `~/gethumanai-landing` and runs `docker compose up -d --build`.
|
|
3. Runs a smoke test — curls the container IP directly and checks for key strings on PL `/`, EN `/en/`, hreflang, and the mailto link. Exits non-zero and prints `FAIL` if any check fails.
|
|
|
|
The container joins the `npm_proxy` Docker network. In **Nginx Proxy Manager** on the VPS,
|
|
create a proxy host: `gethumanai.com` → `http://humanai-landing:80`.
|
|
|
|
## Structure
|
|
|
|
```
|
|
src/
|
|
i18n/
|
|
pl.json # Polish copy (all text)
|
|
en.json # English copy (all text)
|
|
index.ts # translation helpers
|
|
layouts/
|
|
Layout.astro # HTML shell, meta/OG/hreflang
|
|
components/
|
|
Nav.astro
|
|
Hero.astro
|
|
Problem.astro
|
|
HowWeWork.astro
|
|
Offers.astro
|
|
Process.astro
|
|
Security.astro # hidden on MVP (SHOW_SECURITY flag)
|
|
Contact.astro
|
|
Footer.astro
|
|
pages/
|
|
index.astro # PL — /
|
|
en/
|
|
index.astro # EN — /en/
|
|
```
|
|
|
|
## Enabling the Security section
|
|
|
|
Open `src/components/Security.astro` and set `SHOW_SECURITY = true`.
|
|
|
|
## Swapping the logo
|
|
|
|
The logo text and SVG icon are in `src/components/Nav.astro` (`.logo`).
|