Packer hide Virtual Machine GUI – Packer 如何在建立Virtual Machine時 把介面隱藏

在使用Packer的時候 Virtual Box 自動彈出了他的VirtualBox GUI出來
我們可以看到安裝的過程, 十分有趣

如果我們不在執行 Packer
彈出Virtual Machine的介面
我們可以在 Packer的 Template 檔案上把 Headless的設定為 True

headless (boolean) – Packer defaults to building VirtualBox virtual machines by launching a GUI that shows the console of the machine being built. When this value is set to true, the machine will start without a console.

  "disk_size": "{{user `disk_size`}}",
    "headless": "true",
    "http_directory": "http",

Packer Hide Virtual Machine UI during Build - Headless = true
Hope you find it useful

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.