はじめに
あるローカル開発環境構築の学習サイトの内容を書き記していきます。
内容
・Windows + Rコマンドから「Power Shell」を起動
・Vagrant-vbguestのインストールは、不要となった。
作業用フォルダの作成
・作業用フォルダを作成して(PowerShell「mkdir」)、移動する(「cd」)
Vagrantファイルの作成
・Vagrantファイルの作成:PowerShellコマンド「vagrant init bento/centos-6.8」
・Vagrantファイル作成完了の通知
「A `Vagrantfile` has been placed in this directory. You are now
ready to `vagrant up` your first virtual environment! Please read
the comments in the Vagrantfile as well as documentation on
`vagrantup.com` for more information on using Vagrant.」
・フォルダ内の「Vagrantfile」(拡張子なし)をエディタで開く
・IPアドレスの記述行のコメントを外す(有効化する)
例:# config.vm.network "private_network", ip: "192.168.33.10"
・設定ファイルの作成完了
仮想マシンの起動
・PowerShellでコマンド「Vagrant up」
仮想マシンの確認
・PowerShellでコマンド「Vagrant status」
・「runnning」と表示されていれば、仮想マシンが立ち上がっている。
2回目以降の起動
・PowerShellを起動する
・cdコマンドで移動する
・Vagrant upを実行する