--- title: "ncp-iam-authenticator のインストール" slug: "k8s-iam-auth-ncp-iam-authenticator" tags: ["Kubernetes Service", "vpc"] updated: 2026-09-17T09:31:52Z published: 2026-09-17T09:31:52Z canonical: "guide.ncloud-docs.com/k8s-iam-auth-ncp-iam-authenticator" --- > ## Documentation Index > Fetch the complete documentation index at: https://guide.ncloud-docs.com/llms.txt > Use this file to discover all available pages before exploring further. # ncp-iam-authenticator のインストール VPC環境で利用できます。 Ncloud Kubernetes Serviceは、ncp-iam-authenticatorを通じて IAM認証を提供します。IAM認証を通じて kubectlコマンドを使用するには、ncp-iam-authenticatorをインストールしてこれを認証に使用するように kubectlの設定ファイルを修正する必要があります。 参考 APIアクセス制御を使用する場合、メインアカウントでは IAM認証をサポートせず、サブアカウントのみ IAM認証が可能です。 ## macOSのインストール macOSに ncp-iam-authenticatorをインストールする方法は、次の通りです。 #### Homebrewでインストール [Homebrew](https://brew.sh/)でインストールする方法は、次の通りです。 ``` brew tap NaverCloudPlatform/tap brew install ncp-iam-authenticator ``` #### 直接ダウンロードしてインストール 1. ncp-iam-authenticatorバイナリをダウンロードします。(Armバージョンをダウンロードするには、コマンドを実行する前に amd64を arm64に変更します)。 ``` curl -o ncp-iam-authenticator -L https://github.com/NaverCloudPlatform/ncp-iam-authenticator/releases/latest/download/ncp-iam-authenticator_darwin_amd64 ``` 2. (任意) SHA-256 SUMを使用してダウンロードしたバイナリファイルを確認できます。 1. ncp-iam-authenticatorバイナリファイルの SHA-256の合計を確認します。 ``` openssl sha1 -sha256 ncp-iam-authenticator ``` 2. SHA-256 SUMをダウンロードします。 ``` https://github.com/NaverCloudPlatform/ncp-iam-authenticator/releases/latest/download/ncp-iam-authenticator_SHA256SUMS ``` 3. 2つの値が一致しているか確認します。 3. バイナリに実行権限を追加します。 ``` chmod +x ./ncp-iam-authenticator ``` 4. `$HOME/bin/ncp-iam-authenticator`を作成し、`$PATH`に追加します。 ``` mkdir -p $HOME/bin && cp ./ncp-iam-authenticator $HOME/bin/ncp-iam-authenticator && export PATH=$PATH:$HOME/bin ``` 5. Shell Profileに PATHを追加します。 - bash ``` echo 'export PATH=$PATH:$HOME/bin' >> ~/.bash_profile ``` - zsh ``` echo 'export PATH=$PATH:$HOME/bin' >> ~/.zshrc ``` 6. ncp-iam-authenticatorバイナリが正常に動作するかテストします。 ``` ncp-iam-authenticator help ``` ## linuxのインストール linuxに ncp-iam-authenticatorをインストールする方法は、次の通りです。 1. ncp-iam-authenticatorバイナリをダウンロードします(Armバージョンをダウンロードするには、コマンドを実行する前に amd64を arm64に変更します)。 ``` curl -o ncp-iam-authenticator -L https://github.com/NaverCloudPlatform/ncp-iam-authenticator/releases/latest/download/ncp-iam-authenticator_linux_amd64 ``` 2. (任意) SHA-256 SUMを使用してダウンロードしたバイナリファイルを確認できます。 1. ncp-iam-authenticatorバイナリファイルの SHA-256の合計を確認します。 ``` openssl sha1 -sha256 ncp-iam-authenticator ``` 2. SHA-256 SUMをダウンロードします。 ``` curl -o ncp-iam-authenticator.sha256 -L https://github.com/NaverCloudPlatform/ncp-iam-authenticator/releases/latest/download/ncp-iam-authenticator_SHA256SUMS ``` 3. 2つの値が一致しているか確認します。 3. バイナリに実行権限を追加します。 ``` chmod +x ./ncp-iam-authenticator ``` 4. `$HOME/bin/ncp-iam-authenticator`を作成し、`$PATH`に追加します。 ``` mkdir -p $HOME/bin && cp ./ncp-iam-authenticator $HOME/bin/ncp-iam-authenticator && export PATH=$PATH:$HOME/bin ``` 5. Shell Profileに PATHを追加します。 - bash ``` echo 'export PATH=$PATH:$HOME/bin' >> ~/.bash_profile ``` 6. ncp-iam-authenticatorバイナリが正常に動作するかテストします。 ``` ncp-iam-authenticator help ``` ## windowsのインストール windows ncp-iam-authenticatorをインストールする方法は、次の通りです。 1. PowerShellターミナルで ncp-iam-authenticatorバイナリをダウンロードします。 ``` curl -o ncp-iam-authenticator.exe -L https://github.com/NaverCloudPlatform/ncp-iam-authenticator/releases/latest/download/ncp-iam-authenticator_windows_amd64.exe ``` 2. (任意) SHA-256 SUMを使用してダウンロードしたバイナリファイルを確認できます。 1. ncp-iam-authenticatorバイナリファイルの SHA-256合計を確認します。 ``` Get-FileHash ncp-iam-authenticator.exe ``` 2. SHA-256 SUMをダウンロードします。 ``` curl -o ncp-iam-authenticator.sha256 -L https://github.com/NaverCloudPlatform/ncp-iam-authenticator/releases/latest/download/ncp-iam-authenticator_SHA256SUMS ``` 3. 2つの値が一致しているか確認します。 3. C:\binのように、新しいフォルダを作成します。 4. ncp-iam-authenticator.exe実行ファイルをコピーして新しいフォルダに貼り付けます。 5. ユーザーまたはシステム PATH環境変数を編集し、PATHに新しいフォルダを追加します。 6. PowerShellターミナルを閉じ、新しい PATH変数をインポートするために新しいターミナルを開きます。 7. ncp-iam-authenticatorバイナリが正常に動作するかテストします。 ``` ncp-iam-authenticator help ``` ncp-iam-authenticatorのインストールが完了したら、kubeconfigを追加する必要があります。[IAM認証 kubeconfigの作成](/docs/ja/k8s-iam-auth-kubeconfig)をご参照ください。