Skip to content

Commit 7ad44dd

Browse files
committed
update / add instructions for building VMware boxes in the README.md
1 parent 2b2fb71 commit 7ad44dd

1 file changed

Lines changed: 28 additions & 10 deletions

File tree

README.md

Lines changed: 28 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,15 @@ All your specific customizations go in there!
1515

1616
For the Chef-based equivalent of it, see https://github.com/Zuehlke/linux-developer-vm
1717

18-
1918
## What's included?
2019

2120
### Main tools
2221

23-
These are the main tools included in this developer VM (see CHANGELOG for the specific versions):
22+
These are the main tools included in this developer VM:
23+
24+
* ...(add your tools here)
25+
26+
Apart from the above, the following tools are used to set up and maintain this developer VM:
2427

2528
* [Ansible](https://docs.ansible.com/ansible/latest/index.html) - for managing / installing this developer VM
2629
* [Ansible-lint](https://github.com/ansible/ansible-lint) - to ensure best practices when adding more Ansible roles
@@ -61,21 +64,22 @@ You can run these commands from anywhere inside the developer VM:
6164

6265
### Further Usage Instructions
6366

64-
For further instructions, please refer to the README.md that is placed on the Desktop of the Developer VM:
67+
For general instructions, please refer to the README.md that is placed on the Desktop of the Developer VM:
6568

66-
* https://github.com/Zuehlke/linux-developer-vm-with-ansible/blob/master/roles/readme/files/README.md
69+
* [roles/readme/files/README.md](./roles/readme/files/README.md)
6770

6871

69-
## Development
72+
## Building and Packaging the VM
7073

7174
### Prerequisites
7275

73-
You only need [VirtualBox](http://virtualbox.org/wiki/Downloads) and [Vagrant](http://www.vagrantup.com/)
74-
installed.
76+
You only need [VirtualBox](http://virtualbox.org/wiki/Downloads) and [Vagrant](http://www.vagrantup.com/) installed.
77+
78+
If you want to build a VMware .ova image, you will need a [VMware Workstation (Pro) or VMware Fusion](https://www.vmware.com/products/desktop-hypervisor.html) + [Vagrant VMware Plugin](https://www.vagrantup.com/vmware).
7579

7680
All other requirements, including Ansible will be installed *inside the Vagrant VM* during provisioning, i.e. you don't need them installed on your host machine.
7781

78-
### Basic Development Workflow
82+
### Building
7983

8084
Bring up the developer VM:
8185
```
@@ -145,20 +149,34 @@ First, unmount the /vagrant shared folder:
145149
$ vagrant ssh -c "sudo umount /vagrant -f"
146150
```
147151

148-
Finally, shutdown the VM, remove the sharedfolder, and export the VM as an .ova file:
152+
Then remove the vagrant user account:
153+
```
154+
$ vagrant ssh -c "sudo pkill -KILL -u vagrant"
155+
$ vagrant ssh -c "sudo userdel -f -r vagrant"
156+
```
157+
158+
Finally, shutdown the VM, remove the sharedfolder, and export the VM as an .ova file
159+
160+
For VirtualBox:
149161
```
150162
$ vagrant halt
151163
$ VBoxManage sharedfolder remove "Linux Developer VM" --name "vagrant"
152164
$ VBoxManage modifyvm "Linux Developer VM" --name "Linux Developer VM v0.1.0"
153165
$ VBoxManage export "Linux Developer VM v0.1.0" --output "linux-developer-vm-v0.1.0.ova" --options manifest,nomacs
154166
```
155167

168+
For VMware:
169+
```
170+
$ vagrant halt
171+
$ VMX_FILE=`cat .vagrant/machines/default/vmware_desktop/id`
172+
$ ovftool --name="Linux Developer VM v0.1.0" "$VMX_FILE" linux-developer-vm-v0.1.0.ova
173+
```
174+
156175
Don't forget to throw away the VM when you are done:
157176
```
158177
$ vagrant destroy -f
159178
```
160179

161-
162180
## Contributing
163181

164182
1. Fork the repository on Github

0 commit comments

Comments
 (0)