LoginSignup
7
8

More than 5 years have passed since last update.

MacにVagrantでUbuntu14.04をインストールする

Last updated at Posted at 2015-07-27

VirtualBoxのインストール

下記のページからMac OS Xのfileをダウンロードしインストールを行う。

VirtualBoxのダウンロード

Vagrantのインストール

下記のページからMac OS Xのfileをダウンロードしインストールを行う。

Vagrantのインストール

インストール後、ターミナルでversionを確認する。(2015/07/27現在)

$ vagrant version
Installed Version: 1.7.4
Latest Version: 1.7.4

You're running an up-to-date version of Vagrant!

VagrantCloudに登録

※ ユーザー登録しなくてもboxの追加はできますが、登録することでローカルで立ち上げた環境に外部からアクセスできるようになったり、boxを公開できたり色々便利です。

下記のページのヘッダー右側にある[Sign Up & Tutorials]より、新規登録を行ってください。

VagrantCloud

新規登録後、ターミナルでVagrantCloudにログインする。(登録したUsernameとPasswordを入力する)

$ vagrant login
…
Atlas Username: 任意のUsername
Password (will be hidden): 任意のPassword
You are now logged in.

Vagrantにboxを指定し実行

Vagrantbox.esやgithubからboxを追加するのもアリですが、VagrantCloudの方が、boxのダウンロード数も一目で分かり便利で楽だと思います。

Discover Vagrant Boxesからboxを探すことができるので,任意のディレクトリでubuntu/trusty64を指定しvagrantの初期化をする。

$ vagrant init ubuntu/trusty64

Vagrantを実行する。

$ vagrant up

VagrantでUbuntu14.04が立ち上がるはずです。

次回は、今回立ち上げたUbuntuを使ったサーバーの構築をしていこうと思います。

7
8
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
7
8