Skip to content

Commit 10c92f4

Browse files
authored
Merge pull request #23124 from cyberblack28/#23064
Translate docs/setup/production-environment/windows/user-guide-windows-containers/ into Japanese #23064
2 parents 03e4a9e + 9d8efe0 commit 10c92f4

File tree

1 file changed

+54
-54
lines changed

1 file changed

+54
-54
lines changed

content/ja/docs/setup/production-environment/windows/user-guide-windows-containers.md

Lines changed: 54 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,30 @@
11
---
2-
title: Guide for scheduling Windows containers in Kubernetes
2+
title: KubernetesでWindowsコンテナをスケジュールするためのガイド
33
content_type: concept
44
weight: 75
55
---
66

77
<!-- overview -->
88

9-
Windows applications constitute a large portion of the services and applications that run in many organizations. This guide walks you through the steps to configure and deploy a Windows container in Kubernetes.
9+
Windowsアプリケーションは、多くの組織で実行されるサービスとアプリケーションの大部分を占めます。このガイドでは、KubernetesでWindowsコンテナを構成してデプロイする手順について説明します。
1010

1111

1212

1313
<!-- body -->
1414

15-
## Objectives
15+
## 目的
1616

17-
* Configure an example deployment to run Windows containers on the Windows node
18-
* (Optional) Configure an Active Directory Identity for your Pod using Group Managed Service Accounts (GMSA)
17+
* WindowsノードでWindowsコンテナを実行するサンプルのDeploymentを構成します
18+
* (オプション)Group Managed Service Accounts(GMSA)を使用してPodのActive Directory IDを構成します
1919

20-
## Before you begin
20+
## 始める前に
2121

22-
* Create a Kubernetes cluster that includes a [master and a worker node running Windows Server](/ja/docs/setup/production-environment/windows/user-guide-windows-nodes/)
23-
* It is important to note that creating and deploying services and workloads on Kubernetes behaves in much the same way for Linux and Windows containers. [Kubectl commands](/docs/reference/kubectl/overview/) to interface with the cluster are identical. The example in the section below is provided simply to jumpstart your experience with Windows containers.
22+
* [Windows Serverを実行するマスターノードとワーカーノード](/ja/docs/setup/production-environment/windows/user-guide-windows-nodes/)を含むKubernetesクラスターを作成します
23+
* Kubernetes上にServiceとワークロードを作成してデプロイすることは、LinuxコンテナとWindowsコンテナ共に、ほぼ同じように動作することに注意してください。クラスターとのインタフェースとなる[Kubectlコマンド](/docs/reference/kubectl/overview/)も同じです。Windowsコンテナをすぐに体験できる例を以下セクションに用意しています。
2424

25-
## Getting Started: Deploying a Windows container
25+
## はじめに:Windowsコンテナのデプロイ
2626

27-
To deploy a Windows container on Kubernetes, you must first create an example application. The example YAML file below creates a simple webserver application. Create a service spec named `win-webserver.yaml` with the contents below:
27+
WindowsコンテナをKubernetesにデプロイするには、最初にサンプルアプリケーションを作成する必要があります。以下のYAMLファイルの例では、簡単なウェブサーバーアプリケーションを作成しています。以下の内容で`win-webserver.yaml`という名前のサービススペックを作成します。:
2828

2929
```yaml
3030
apiVersion: v1
@@ -35,7 +35,7 @@ metadata:
3535
app: win-webserver
3636
spec:
3737
ports:
38-
# the port that this service should serve on
38+
# このサービスが提供するポート
3939
- port: 80
4040
targetPort: 80
4141
selector:
@@ -71,73 +71,74 @@ spec:
7171
```
7272
7373
{{< note >}}
74-
Port mapping is also supported, but for simplicity in this example the container port 80 is exposed directly to the service.
74+
ポートマッピングもサポートされていますが、この例では簡単にするために、コンテナポート80がサービスに直接公開されています。
7575
{{< /note >}}
7676
77-
1. Check that all nodes are healthy:
77+
1. すべてのノードが正常であることを確認します。:
7878
7979
```bash
8080
kubectl get nodes
8181
```
8282

83-
1. Deploy the service and watch for pod updates:
83+
1. Serviceをデプロイして、Podの更新を確認します。:
8484

8585
```bash
8686
kubectl apply -f win-webserver.yaml
8787
kubectl get pods -o wide -w
8888
```
8989

90-
When the service is deployed correctly both Pods are marked as Ready. To exit the watch command, press Ctrl+C.
90+
Serviceが正しくデプロイされると、両方のPodがReadyとして表示されます。watch状態のコマンドを終了するには、Ctrl + Cを押します。
9191

92-
1. Check that the deployment succeeded. To verify:
92+
1. デプロイが成功したことを確認します。検証するために行うこと:
9393

94-
* Two containers per pod on the Windows node, use `docker ps`
95-
* Two pods listed from the Linux master, use `kubectl get pods`
96-
* Node-to-pod communication across the network, `curl` port 80 of your pod IPs from the Linux master to check for a web server response
97-
* Pod-to-pod communication, ping between pods (and across hosts, if you have more than one Windows node) using docker exec or kubectl exec
98-
* Service-to-pod communication, `curl` the virtual service IP (seen under `kubectl get services`) from the Linux master and from individual pods
99-
* Service discovery, `curl` the service name with the Kubernetes [default DNS suffix](/ja/docs/concepts/services-networking/dns-pod-service/#services)
94+
* WindowsノードのPodごとの2つのコンテナに`docker ps`します
95+
* Linuxマスターからリストされた2つのPodに`kubectl get pods`します
96+
* ネットワークを介したノードとPod間通信、LinuxマスターからのPod IPのポート80に向けて`curl`して、ウェブサーバーの応答をチェックします
97+
* docker execまたはkubectl execを使用したPod間通信、Pod間(および複数のWindowsノードがある場合はホスト間)へのpingします
98+
* ServiceからPodへの通信、Linuxマスターおよび個々のPodからの仮想Service IP(`kubectl get services`で表示される)に`curl`します
99+
* サービスディスカバリ、Kuberntesの[default DNS suffix](/ja/docs/concepts/services-networking/dns-pod-service/#services)と共にService名に`curl`します
100100
* Inbound connectivity, `curl` the NodePort from the Linux master or machines outside of the cluster
101-
* Outbound connectivity, `curl` external IPs from inside the pod using kubectl exec
101+
* インバウンド接続、Linuxマスターまたはクラスター外のマシンからNodePortに`curl`します
102+
* アウトバウンド接続、kubectl execを使用したPod内からの外部IPに`curl`します
102103

103104
{{< note >}}
104-
Windows container hosts are not able to access the IP of services scheduled on them due to current platform limitations of the Windows networking stack. Only Windows pods are able to access service IPs.
105+
今のところ、Windowsネットワークスタックのプラットフォーム制限のため、Windowsコンテナホストは、ホストされているサービスのIPにアクセスできません。Service IPにアクセスできるのは、Windows Podだけです。
105106
{{< /note >}}
106107

107-
## Observability
108+
## 可観測性
108109

109-
### Capturing logs from workloads
110+
### ワークロードからのログキャプチャ
110111

111-
Logs are an important element of observability; they enable users to gain insights into the operational aspect of workloads and are a key ingredient to troubleshooting issues. Because Windows containers and workloads inside Windows containers behave differently from Linux containers, users had a hard time collecting logs, limiting operational visibility. Windows workloads for example are usually configured to log to ETW (Event Tracing for Windows) or push entries to the application event log. [LogMonitor](https://github.com/microsoft/windows-container-tools/tree/master/LogMonitor), an open source tool by Microsoft, is the recommended way to monitor configured log sources inside a Windows container. LogMonitor supports monitoring event logs, ETW providers, and custom application logs, piping them to STDOUT for consumption by `kubectl logs <pod>`.
112+
ログは可観測性の重要な要素です。これにより、ユーザーはワークロードの運用面に関する洞察を得ることができ、問題のトラブルシューティングの主要な要素になります。WindowsコンテナとWindowsコンテナ内のワークロードの動作はLinuxコンテナとは異なるため、ユーザーはログの収集に苦労し、運用の可視性が制限されていました。たとえば、Windowsワークロードは通常、ETW(Windowsのイベントトレース)にログを記録するか、アプリケーションイベントログにエントリをプッシュするように構成されます。Microsoftのオープンソースツールである[LogMonitor](https://github.com/microsoft/windows-container-tools/tree/master/LogMonitor)は、Windowsコンテナ内の構成されたログソースを監視するための推奨方法です。LogMonitorは、イベントログ、ETWプロバイダー、カスタムアプリケーションログのモニタリングをサポートしており、それらをSTDOUTにパイプして、`kubectl logs <pod>`で使用できます。
112113

113-
Follow the instructions in the LogMonitor GitHub page to copy its binaries and configuration files to all your containers and add the necessary entrypoints for LogMonitor to push your logs to STDOUT.
114+
LogMonitor GitHubページの指示に従って、バイナリと構成ファイルをすべてのコンテナにコピーして、LogMonitorがログをSTDOUTにプッシュするために必要なエントリーポイントを追加します。
114115

115-
## Using configurable Container usernames
116+
## 構成可能なコンテナのユーザー名の使用
116117

117-
Starting with Kubernetes v1.16, Windows containers can be configured to run their entrypoints and processes with different usernames than the image defaults. The way this is achieved is a bit different from the way it is done for Linux containers. Learn more about it [here](/docs/tasks/configure-pod-container/configure-runasusername/).
118+
Kubernetes v1.16以降、Windowsコンテナは、イメージのデフォルトとは異なるユーザー名でエントリーポイントとプロセスを実行するように構成できます。これが達成される方法は、Linuxコンテナで行われる方法とは少し異なります。詳しくは[こちら](/docs/tasks/configure-pod-container/configure-runasusername/).
118119

119-
## Managing Workload Identity with Group Managed Service Accounts
120+
## Group Managed Service AccountsによるワークロードIDの管理
120121

121-
Starting with Kubernetes v1.14, Windows container workloads can be configured to use Group Managed Service Accounts (GMSA). Group Managed Service Accounts are a specific type of Active Directory account that provides automatic password management, simplified service principal name (SPN) management, and the ability to delegate the management to other administrators across multiple servers. Containers configured with a GMSA can access external Active Directory Domain resources while carrying the identity configured with the GMSA. Learn more about configuring and using GMSA for Windows containers [here](/docs/tasks/configure-pod-container/configure-gmsa/).
122+
Kubernetes v1.14以降、Windowsコンテナワークロードは、Group Managed Service Accounts(GMSA)を使用するように構成できます。Group Managed Service Accountsは、自動パスワード管理、簡略化されたサービスプリンシパル名(SPN)管理、および複数のサーバー間で他の管理者に管理を委任する機能を提供する特定の種類のActive Directoryアカウントです。GMSAで構成されたコンテナは、GMSAで構成されたIDを保持しながら、外部Active Directoryドメインリソースにアクセスできます。Windowsコンテナ用のGMSAの構成と使用の詳細は[こちら](/docs/tasks/configure-pod-container/configure-gmsa/)
122123

123-
## Taints and Tolerations
124+
## TaintsとTolerations
124125

125-
Users today need to use some combination of taints and node selectors in order to keep Linux and Windows workloads on their respective OS-specific nodes. This likely imposes a burden only on Windows users. The recommended approach is outlined below, with one of its main goals being that this approach should not break compatibility for existing Linux workloads.
126+
今日のユーザーは、LinuxとWindowsのワークロードをそれぞれのOS固有のノードで維持するために、Taintsとノードセレクターのいくつかの組み合わせを使用する必要があります。これはおそらくWindowsユーザーにのみ負担をかけます。推奨されるアプローチの概要を以下に示します。主な目標の1つは、このアプローチによって既存のLinuxワークロードの互換性が損なわれないようにすることです。
126127

127-
### Ensuring OS-specific workloads land on the appropriate container host
128+
### OS固有のワークロードが適切なコンテナホストに確実に到達するようにする
128129

129-
Users can ensure Windows containers can be scheduled on the appropriate host using Taints and Tolerations. All Kubernetes nodes today have the following default labels:
130+
ユーザーは、TaintsとTolerationsを使用して、Windowsコンテナを適切なホストでスケジュールできるようにすることができます。現在、すべてのKubernetesノードには次のデフォルトラベルがあります。:
130131

131132
* kubernetes.io/os = [windows|linux]
132133
* kubernetes.io/arch = [amd64|arm64|...]
133134

134-
If a Pod specification does not specify a nodeSelector like `"kubernetes.io/os": windows`, it is possible the Pod can be scheduled on any host, Windows or Linux. This can be problematic since a Windows container can only run on Windows and a Linux container can only run on Linux. The best practice is to use a nodeSelector.
135+
Podの仕様で`"kubernetes.io/os": windows`のようなnodeSelectorが指定されていない場合、PodをWindowsまたはLinuxの任意のホストでスケジュールすることができます。WindowsコンテナはWindowsでのみ実行でき、LinuxコンテナはLinuxでのみ実行できるため、これは問題になる可能性があります。ベストプラクティスは、nodeSelectorを使用することです。
135136

136-
However, we understand that in many cases users have a pre-existing large number of deployments for Linux containers, as well as an ecosystem of off-the-shelf configurations, such as community Helm charts, and programmatic Pod generation cases, such as with Operators. In those situations, you may be hesitant to make the configuration change to add nodeSelectors. The alternative is to use Taints. Because the kubelet can set Taints during registration, it could easily be modified to automatically add a taint when running on Windows only.
137+
ただし、多くの場合、ユーザーには既存の多数のLinuxコンテナのdepolyment、およびコミュニティHelmチャートのような既成構成のエコシステムやOperatorのようなプログラム的にPodを生成するケースがあることを理解しています。このような状況では、nodeSelectorsを追加するための構成変更をためらう可能性があります。代替策は、Taintsを使用することです。kubeletは登録中にTaintsを設定できるため、Windowsだけで実行する時に自動的にTaintを追加するように簡単に変更できます。
137138

138-
For example: `--register-with-taints='os=windows:NoSchedule'`
139+
例:`--register-with-taints='os=windows:NoSchedule'`
139140

140-
By adding a taint to all Windows nodes, nothing will be scheduled on them (that includes existing Linux Pods). In order for a Windows Pod to be scheduled on a Windows node, it would need both the nodeSelector to choose Windows, and the appropriate matching toleration.
141+
すべてのWindowsノードにTaintを追加することにより、それらには何もスケジュールされません(既存のLinuxPodを含む)。Windows PodがWindowsノードでスケジュールされるためには、nodeSelectorがWindowsを選択することと、適切にマッチするTolerationが必要です。
141142

142143
```yaml
143144
nodeSelector:
@@ -150,28 +151,27 @@ tolerations:
150151
effect: "NoSchedule"
151152
```
152153

153-
### Handling multiple Windows versions in the same cluster
154+
### 同じクラスター内の複数Windowsバージョンの管理
154155

155-
The Windows Server version used by each pod must match that of the node. If you want to use multiple Windows
156-
Server versions in the same cluster, then you should set additional node labels and nodeSelectors.
156+
各Podで使用されるWindows Serverのバージョンは、ノードのバージョンと一致している必要があります。
157+
同じクラスター内で複数のWindows Serverバージョンを使用したい場合は、追加のノードラベルとnodeSelectorsを設定する必要があります。
157158

158-
Kubernetes 1.17 automatically adds a new label `node.kubernetes.io/windows-build` to simplify this. If you're running an older version, then it's recommended to add this label manually to Windows nodes.
159+
Kubernetes 1.17では、これを簡単するために新しいラベル`node.kubernetes.io/windows-build`が自動的に追加されます。古いバージョンを実行している場合は、このラベルをWindowsノードに手動で追加することをお勧めします。
159160

160-
This label reflects the Windows major, minor, and build number that need to match for compatibility. Here are values used today for each Windows Server version.
161+
このラベルは、互換性のために一致する必要があるWindowsのメジャー、マイナー、およびビルド番号を反映しています。以下は、Windows Serverの各バージョンで現在使用されている値です。
161162

162-
| Product Name | Build Number(s) |
163+
| 製品番号    | ビルド番号 |
163164
|--------------------------------------|------------------------|
164165
| Windows Server 2019 | 10.0.17763 |
165166
| Windows Server version 1809 | 10.0.17763 |
166167
| Windows Server version 1903 | 10.0.18362 |
167168

168169

169-
### Simplifying with RuntimeClass
170+
### RuntimeClassによる簡素化
170171

171-
[RuntimeClass] can be used to simplify the process of using taints and tolerations. A cluster administrator can create a `RuntimeClass` object which is used to encapsulate these taints and tolerations.
172+
[RuntimeClass]は、TaintsとTolerationsを使用するプロセスを簡略化するために使用できます。クラスター管理者は、これらのTaintsとTolerationsをカプセル化するために使用する`RuntimeClass`オブジェクトを作成できます。
172173

173-
174-
1. Save this file to `runtimeClasses.yml`. It includes the appropriate `nodeSelector` for the Windows OS, architecture, and version.
174+
1. このファイルを`runtimeClasses.yml`に保存します。これには、Windows OS、アーキテクチャ、およびバージョンに適切な`nodeSelector`が含まれています。
175175

176176
```yaml
177177
apiVersion: node.k8s.io/v1beta1
@@ -191,10 +191,10 @@ scheduling:
191191
value: "windows"
192192
```
193193

194-
1. Run `kubectl create -f runtimeClasses.yml` using as a cluster administrator
195-
1. Add `runtimeClassName: windows-2019` as appropriate to Pod specs
194+
1. クラスター管理者として使用する`kubectl create -f runtimeClasses.yml`を実行します
195+
1. Podの仕様に応じて`runtimeClassName: windows-2019`を追加します
196196

197-
For example:
197+
:
198198

199199
```yaml
200200
apiVersion: apps/v1
@@ -241,4 +241,4 @@ spec:
241241
app: iis-2019
242242
```
243243

244-
[RuntimeClass]: https://kubernetes.io/docs/concepts/containers/runtime-class/
244+
[RuntimeClass]: https://kubernetes.io/docs/concepts/containers/runtime-class/

0 commit comments

Comments
 (0)