LoginSignup
4
2

More than 3 years have passed since last update.

vagrant で Internet Explorer の検証環境を構築する 2019年版(Microsoft Edge Developer)

Last updated at Posted at 2019-10-17

参考記事

ほぼ以下の内容と一緒です

Mac × VagrantでWindows7 × IE11の環境をつくる!

手順

vagrant, VirtualBox をインストール

$ brew cask install vagrant
$ brew cask install virtualbox

# virtualbox のインストールに失敗する場合は不要なリポジトリを untap する
#   ref: https://github.com/Homebrew/homebrew-cask/issues/66037
#
#$ brew untap caskroom/cask caskroom/versions

対象の box イメージをダウンロード、unzip

以下の例では Win7 IE11 をダウンロードしています。

# Vagrant - Win7 IE11
$ curl -OL https://az792536.vo.msecnd.net/vms/VMBuild_20190311/Vagrant/MSEdge/MSEdge.Win10.Vagrant.zip
$ unzip IE11.Win7.Vagrant.zip

直リンクで取れなかったら以下から vagrant → 任意の OS、ブラウザを選んでダウンロードする

作業ディレクトリ作成、VagrantFile を準備

$ mkdir win7_ie11; cd $_
$ vagrant init
$ cat > Vagrantfile

以下の内容をコピーペーストして Ctrl + D

Vagrantfile
Vagrant.configure("2") do |config|
  # vagrant box addで追加したbox名を指定
  config.vm.box = "win7_ie11"

  # GUIの使用とメモリの設定
  config.vm.provider "virtualbox" do |vb|
    vb.gui = true
    vb.memory = "2048"
  end

  # ゲストOSを指定
  config.vm.guest = "windows"

  # SSHの設定
  config.ssh.username = "IEUser"
  config.ssh.password = "Passw0rd!"
  config.ssh.insert_key = false
  config.ssh.shell = 'sh -l'
end

ssh のID/パスワードが変わっていたら View installation instructions で確認して正しいものを入力する

起動

$ vagrant up

補足

  • 共有フォルダはデフォルトで host:<作業ディレクトリ>guest:C:\vagrant\ に設定される。
    変更したい場合は config.vm.synced_folder を設定する
4
2
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
4
2