Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs: add clever cloud deploy #1668

Merged
merged 7 commits into from
Jan 20, 2025
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
64 changes: 64 additions & 0 deletions content/3.deploy/clever-cloud.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
---
title: Clever Cloud
description: 'Deploy your Nuxt Application to Clever Cloud infrastructure.'
logoSrc: '/assets/integrations/clever-cloud.svg'
category: Hosting
nitroPreset: 'node_server'
website: 'https://www.clever-cloud.com/'
---

Nuxt supports deploying on [Clever Cloud](https://www.clever-cloud.com/) with minimal configuration.

## Install CLI and login.

```bash [Terminal]
npm i -g clever-tools
clever login
```

## Deploy a static application
maximepvrt marked this conversation as resolved.
Show resolved Hide resolved

1. Create a new Clever Cloud Node app.

```bash [Terminal]
clever create -t node myNuxtApp
```

2. Configure your app.

```bash [Terminal]
clever env set CC_NODE_BUILD_TOOL "custom"
clever env set CC_PRE_BUILD_HOOK "npm install -g pnpm && pnpm install"
clever env set CC_CUSTOM_BUILD_TOOL "pnpm build"
clever env set CC_RUN_COMMAND "node .output/server/index.mjs"
```

maximepvrt marked this conversation as resolved.
Show resolved Hide resolved

## Deploy a static application

1. Create a new Clever Cloud static app.

```bash [Terminal]
clever create -t static-apache myStaticNuxtApp
```

2. Configure your app

```bash [Terminal]
clever env set CC_NODE_BUILD_TOOL "custom"
clever env set CC_PRE_BUILD_HOOK "npm install -g pnpm && pnpm install"
clever env set CC_CUSTOM_BUILD_TOOL "pnpm build"
clever env set CC_POST_BUILD_HOOK "pnpm generate"
clever env set CC_WEBROOT "/.output/public"
clever env set CC_OVERRIDE_BUILDCACHE "/.output/public"
```

## Learn more

::read-more{to="https://developers.clever-cloud.com/doc/applications/javascript/nodejs" target="_blank"}
Clever Cloud documentation for deploying a Node.js application
::

::read-more{to="https://developers.clever-cloud.com/guides/nuxt" target="_blank"}
Clever Cloud documentation for deploying Nuxt as a static application
::
10 changes: 10 additions & 0 deletions public/assets/integrations/clever-cloud.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.