LoginSignup
0
0

More than 5 years have passed since last update.

Check! DC/OS CLI を Windows にインストールする

Posted at

こんにちは、オークファンの @dz_ こと大平かづみです。

Prologue - はじめに

DC/OS の CLI を Windows にインストールしてみます。

以下のドキュメントを参考に進めました。このドキュメントには、 Mac, Linux でのインストール方法も記載があります。

前提条件

  • pip がインストールされていること
  • 管理者権限で PowerShell のプロンプトを使います

インストール手順

インストーラーの準備

# virtualenv をインストールする
PS> pip install virtualenv

# インストール先のディレクトリを作成する
PS> mkdir dcos && cd dcos

# インストーラーをダウンロードする
PS> wget https://downloads.dcos.io/dcos-cli/install.ps1 -OutFile install.ps1

# インストーラーの実行権限を調整する
PS> set-executionpolicy Unrestricted -Scope Process

インストール

インストールする際は、「masterノードへのURL」を指定します。 Azure Container Service を利用する場合は、SSHトンネル接続後 localhost で接続するので、 http://localhost としてください。

また、途中で環境変数の PATH に追加してよいか聞かれますので、 Y と答えて進めてください。

# インストールを実行する
PS> .\install.ps1 . https://<masterノードへのURL>

True
True
Installing DCOS CLI from PyPI...

New python executable in C:\Users\user\dcos\Scripts\python.exe
Installing setuptools, pip, wheel...done.


    ディレクトリ: C:\Users\user


Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----       2016/06/07     17:01                .dcos


    ディレクトリ: C:\Users\user\.dcos


Mode                LastWriteTime         Length Name
----                -------------         ------ ----
-a----       2016/06/07     17:01              0 dcos.toml
[core.reporting]: set to 'True'
[core.dcos_url]: set to 'http://<masterノードへのURL>'
[core.timeout]: set to '5'
Modify your Environment to add DCOS to your PATH?
[Y] Yes  [N] No  [?] ヘルプ (既定値は "Y"): Y    # <-- Y を入力


Finished installing and configuring DCOS CLI.

Run this command to set up your environment and to get started:
& activate.ps1; dcos help
# dcos を有効にする
PS> & .\Scripts\activate.ps1; dcos help

これで、 dcos コマンドが使えるようになりました!

Epilogue - おわりに

dcos コマンドを使って何ができるかを、引き続き確認していきます。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0