Skip to content
This repository was archived by the owner on Jan 20, 2025. It is now read-only.

Commit 616ad4f

Browse files
authored
Translate docs/recipies/deploying-your-site.md (#88)
Translate docs/recipies/deploying-your-site.md
2 parents 0794ed3 + 9b5a340 commit 616ad4f

File tree

1 file changed

+48
-47
lines changed

1 file changed

+48
-47
lines changed
Lines changed: 48 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,105 +1,106 @@
11
---
2-
title: "Recipes: Deploying Your Site"
2+
title: "レシピ: サイトをデプロイする"
33
---
44

5-
Showtime. Once you are happy with your site, you are ready to go live with it!
5+
ショータイム。満足ゆくサイトができたら、あとはそれをデプロイするだけです。
66

7-
## Preparing for deployment
7+
## デプロイの準備
88

9-
### Prerequisites
9+
### 前提条件
1010

11-
- A [Gatsby site](/docs/quick-start)
12-
- The [Gatsby CLI](/docs/gatsby-cli) installed
11+
- [Gatsby サイト](/docs/quick-start)
12+
- [Gatsby CLI](/docs/gatsby-cli)がインストールされていること
1313

14-
### Directions
14+
### 手順
1515

16-
1. Stop your development server if it is running (`Ctrl + C` on your command line in most cases)
16+
1. 開発サーバーが起動している場合は停止します。(多くの場合はコマンドラインで `Ctrl + C`
1717

18-
2. For the standard site path at the root directory (`/`), run `gatsby build` using the Gatsby CLI on the command line. The built files will now be in the `public` folder.
18+
2. ルートディレクトリー(`/`)の標準のサイトパスをビルドするには、Gatsby CLI の `gatsby build` を使います。ビルドされたファイルは `public` フォルダーに置かれます。
1919

2020
```shell
2121
gatsby build
2222
```
2323

24-
3. To include a site path other than `/` (such as `/site-name/`), set a path prefix by adding the following to your `gatsby-config.js` and replacing `yourpathprefix` with your desired path prefix:
24+
3. `/` 以外のサイトパス(`/site-name/` など)をビルドするには、`gatsby-config.js` に次のようにパスのプレフィックスを追記してください。
2525

2626
```js:title=gatsby-config.js
2727
module.exports = {
28+
// `/yourpathprefix`を任意のパスに置換
2829
pathPrefix: `/yourpathprefix`,
2930
}
3031
```
3132

32-
There are a few reasons to do this -- for instance, hosting a blog built with Gatsby on a domain with another site not built on Gatsby. The main site would direct to `example.com`, and the Gatsby site with a path prefix could live at `example.com/blog`.
33+
これにはいくつかの用途があります -- 例えば、Gatsby 製のブログサイトを Gatsby 製でないサイトと同じドメインでホストする場合です。サイト本体を `example.com` で動かし、パスプレフィックスを設定した Gatsby サイトは `example.com/blog` 以下に置くことができます。
3334

34-
4. With a path prefix set in `gatsby-config.js`, run `gatsby build` with the `--prefix-paths` flag to automatically add the prefix to the beginning of all Gatsby site URLs and `<Link>` tags.
35+
4. パスのプレフィクスを `gatsby-config.js` に設定した後、`gatsby build` `--prefix-paths` フラグをつけて実行することで、Gatsby サイトの URL と `<Link>` タグのはじめに設定したプレフィクスを自動的に追加できます。
3536

3637
```shell
3738
gatsby build --prefix-paths
3839
```
3940

40-
5. Make sure that your site looks the same when running `gatsby build` as with `gatsby develop`. By running `gatsby serve` when you build your site, you can test out (and debug if necessary) the finished product before deploying it live.
41+
5. `gatsby build` でビルドした時と `gatsby develop` で動作させた時とでサイトの見た目が変わらないことを確認しましょう。ビルド後に `gatsby serve` をすることで、本番環境へデプロイする前にビルド成果物を確認(またはデバッグ)できます。
4142

4243
```shell
4344
gatsby build && gatsby serve
4445
```
4546

46-
### Additional resources
47+
### 追加資料
4748

48-
- Walk through building and deploying an example site in [tutorial part one](/tutorial/part-one/#deploying-a-gatsby-site)
49-
- Learn about [performance optimization](/docs/performance/)
50-
- Read about [other deployment related topics](/docs/preparing-for-deployment/)
51-
- Check out the [deployment docs](/docs/deploying-and-hosting/) for specific hosting platforms and how to deploy to them
49+
- サイトを作成しデプロイするまでの一連の[チュートリアル(その 1)](/tutorial/part-one/#deploying-a-gatsby-site)
50+
- [パフォーマンス最適化](/docs/performance/)について学ぶ
51+
- [他のデプロイ関連のトピックス](/docs/preparing-for-deployment/)について読む
52+
- その他ホスティングサービスへのデプロイ方法についての[ドキュメント](/docs/deploying-and-hosting/)
5253

53-
## Deploying to Netlify
54+
## Netlify にデプロイする
5455

55-
Use [`netlify-cli`](https://www.netlify.com/docs/cli/) to deploy your Gatsby application without leaving the command-line interface.
56+
[`netlify-cli`](https://www.netlify.com/docs/cli/) を使って Gatsby アプリケーションをコマンドラインからデプロイできます。
5657

57-
### Prerequisites
58+
### 前提条件
5859

59-
- A [Gatsby site](/docs/quick-start) with a single component `index.js`
60-
- The [netlify-cli](https://www.npmjs.com/package/netlify-cli) package installed
61-
- The [Gatsby CLI](/docs/gatsby-cli) installed
60+
- `index.js` コンポーネントを持った [Gatsby サイト](/docs/quick-start)
61+
- [netlify-cli](https://www.npmjs.com/package/netlify-cli)パッケージがインストールされていること
62+
- [Gatsby CLI](/docs/gatsby-cli)がインストールされていること
6263

63-
### Directions
64+
### 手順
6465

65-
1. Build your gatsby application using `gatsby build`
66+
1. `gatsby build` で Gatsby アプリケーションをビルドします。
6667

67-
2. Login into Netlify using `netlify login`
68+
2. `netlify login` で Netlify にログインします。
6869

69-
3. Run the command `netlify init`. Select the "Create & configure a new site" option.
70+
3. `netlify init` を実行し、"Create & configure a new site"(新規サイトを作成/設定)オプションを選択します。
7071

71-
4. Choose a custom website name if you want or press enter to receive a random one.
72+
4. あなたのサイト名を入力します。あるいは空欄のまま Enter を押すとランダムな名前が付けられます。
7273

73-
5. Choose your [Team](https://www.netlify.com/docs/teams/).
74+
5. [チーム](https://www.netlify.com/docs/teams/)を選択します。
7475

75-
6. Change the deploy path to `public/`
76+
6. デプロイパスを `public/` に変更します。
7677

77-
7. Make sure that everything looks fine before deploying to production using `netlify deploy --prod`
78+
7. 正常に動作していることを確認できたら `netlify deploy --prod` で本番環境にデプロイします。
7879

79-
### Additional resources
80+
### 追加資料
8081

81-
- [Hosting on Netlify](/docs/hosting-on-netlify)
82+
- [Netlify でホストする](/docs/hosting-on-netlify)
8283
- [gatsby-plugin-netlify](/packages/gatsby-plugin-netlify)
8384

84-
## Deploying to ZEIT Now
85+
## ZEIT Now にデプロイする
8586

86-
Use [Now CLI](https://zeit.co/download) to deploy your Gatsby application without leaving the command-line interface.
87+
[Now CLI](https://zeit.co/download)を使って Gatsby アプリケーションをコマンドラインからデプロイできます。
8788

88-
### Prerequisites
89+
### 前提条件
8990

90-
- A [ZEIT Now](https://zeit.co/signup) account
91-
- A [Gatsby site](/docs/quick-start) with a single component `index.js`
92-
- [Now CLI](https://zeit.co/download) package installed
93-
- [Gatsby CLI](/docs/gatsby-cli) installed
91+
- [ZEIT Now](https://zeit.co/signup)アカウント
92+
- `index.js` コンポーネントを持った [Gatsby サイト](/docs/quick-start)
93+
- [Now CLI](https://zeit.co/download)パッケージがインストールされていること
94+
- [Gatsby CLI](/docs/gatsby-cli)がインストールされていること
9495

95-
### Directions
96+
### 手順
9697

97-
1. Login into Now CLI using `now login`
98+
1. `now login`Now CLI にログインします。
9899

99-
2. Change to the directory of your Gatsby.js application in the Terminal if you aren't already there
100+
2. Gatsby アプリケーションディレクトリーに移動します。
100101

101-
3. Run `now` to deploy it
102+
3. `now` でデプロイします。
102103

103-
### Additional resources
104+
### 追加資料
104105

105-
- [Deploying to ZEIT Now](/docs/deploying-to-zeit-now/)
106+
- [ZEIT Now にデプロイする](/docs/deploying-to-zeit-now/)

0 commit comments

Comments
 (0)