Clever Cloud
Clever Cloud is a PaaS that deploys applications from Git. pageflare integrates through environment-based build hooks or custom build scripts.
How It Works
Section titled “How It Works”Clever Cloud runs your build command during deployment. Add pageflare to the build script in your package.json or use Clever Cloud’s build hook environment variable.
Step 1 — Install pageflare
Section titled “Step 1 — Install pageflare”npm install -D @pageflare/cliStep 2 — Configure the Build
Section titled “Step 2 — Configure the Build”Option A: package.json build script
Section titled “Option A: package.json build script”{ "scripts": { "build": "astro build && npx @pageflare/cli dist/ --in-place --no-progress" }}Option B: Environment variable hook
Section titled “Option B: Environment variable hook”Set CC_POST_BUILD_HOOK in the Clever Cloud console or CLI:
clever env set CC_POST_BUILD_HOOK "npx @pageflare/cli dist/ --in-place --no-progress"Step 3 — Pro License
Section titled “Step 3 — Pro License”Set the environment variable via the Clever Cloud CLI or console:
clever env set PAGEFLARE_LICENSE your-license-keyOr in the console: Environment variables tab.
Step 4 — Verify
Section titled “Step 4 — Verify”Check the deployment logs in the Clever Cloud console for the pageflare summary:
Done 145.2 KB saved (38.1%) 1.2s Files 42 total, 38 optimized, 4 unchanged, 0 errorsFramework Output Directories
Section titled “Framework Output Directories”| Framework | Output directory |
|---|---|
| Astro | dist/ |
| Next.js static export | out/ |
| Hugo | public/ |
| Vite | dist/ |
| Eleventy | _site/ |
Troubleshooting
Section titled “Troubleshooting”Build hook not running
Make sure CC_POST_BUILD_HOOK is set correctly. The hook runs after the main build command completes.
pageflare processes 0 files The output directory doesn’t match your framework’s output. Update the path in the build script or hook.