Nuxt

Nuxtアプリをデプロイ

Nuxt 3's default build target is a Node server, not static files — so the command that gets you a folder of HTML isn't the one in the getting-started guide. generate is the one you want.

steps
  1. 01

    Run generate, not build

    "npm run build" produces a Node server (".output/server"). "npm run generate" pre-renders every route to static HTML instead — that's the one this host needs.

  2. 02

    Find the output folder

    Nuxt 3 writes static output to ".output/public". If you're still on Nuxt 2, "nuxt generate" writes to "dist" instead.

  3. 03

    デプロイする

    プロジェクトのルートで「npx harvis deploy .output/public」を実行してください。この最初のデプロイに設定もログインも不要 — すぐに公開URLが手に入り、いつでも無料アカウントにサイトを紐付けられる非公開のオーナー登録リンクも一緒に発行されます。

Nuxtをコマンド1つでデプロイ

プロジェクトをビルドして、出力フォルダをharvisに渡すだけ。最初のデプロイにアカウントは不要 — 公開リンクと、あとで管理するための非公開のオーナー登録リンクが手に入ります。

terminal
npm run generate
npx harvis deploy .output/public

ターミナルよりファイルをドラッグする方が好みですか?プロジェクトをビルドしたら、出力フォルダをここにドロップすれば同じように公開できます。

Nuxtのデプロイに関する質問

I ran npm run build by mistake — what changes?

That produced a ".output/server" folder meant to run under Node — it has no index.html and won't serve as static files. Run "npm run generate" instead; it pre-renders the same app to ".output/public".

Do dynamic routes and Nuxt's server API routes work?

Page routes work if Nuxt can enumerate them at generate time (static or with a "nitro.prerender.routes" list for dynamic segments). API routes under "server/api" need a server to run and won't work here — call an external API from the client instead.

Nuxtアプリをharvisにデプロイするのは本当に無料ですか?

はい、クレジットカードは不要です。無料枠は1サイトあたり500ファイル・50 MBで、静的なNuxtのビルドなら十分すぎるほどです。公開したサイトに有効期限はなく、削除するまで公開され続けます。

デプロイしたNuxtサイトに独自ドメインは使えますか?

どのサイトも無料のharvis.devアドレスが割り当てられ、オーナー登録後にダッシュボードから好きなサブドメインを選べます(ランダムな名前の代わりにmy-app.harvis.devのように)。すでに持っている独自ドメイン(mystore.comなど)をサイトに向ける機能は、まだ用意されていません。

NuxtをVercelやNetlifyにデプロイするのと何が違いますか?

VercelやNetlifyは、Gitリポジトリを接続してビルドを自分たちのサーバー上で実行し、ダッシュボードで設定する仕組みが中心です。harvisはそれをすべて省略します。ローカル(または自分のCI)でビルドし、出力フォルダに対してCLIコマンドを1つ実行するだけでリンクが手に入ります — プロジェクトの設定も、サイトを残しておきたくなるまでのアカウントも不要です。

other frameworks

別のものをデプロイしますか?

手順はどれでも同じです — ビルドしてから、出力フォルダをnpx harvis deployするだけ。