veewee 0.4.3 → 0.4.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/doc/basics.md +7 -7
- data/doc/customize.md +1 -2
- data/lib/veewee/definition.rb +2 -2
- data/lib/veewee/provider/core/box/build.rb +20 -22
- data/lib/veewee/provider/core/box/copy.rb +7 -1
- data/lib/veewee/provider/core/box/vnc.rb +16 -17
- data/lib/veewee/provider/core/box/wincp.rb +1 -2
- data/lib/veewee/provider/core/helper/ssh.rb +4 -0
- data/lib/veewee/provider/core/helper/web.rb +27 -22
- data/lib/veewee/provider/core/helper/winrm.rb +4 -0
- data/lib/veewee/provider/kvm/box.rb +0 -1
- data/lib/veewee/provider/kvm/box/up.rb +5 -0
- data/lib/veewee/provider/parallels/box.rb +0 -1
- data/lib/veewee/provider/vmfusion/box.rb +0 -2
- data/lib/veewee/version.rb +1 -1
- data/templates/CentOS-4.8-i386/definition.rb +1 -1
- data/templates/CentOS-5.10-i386-netboot/definition.rb +1 -1
- data/templates/CentOS-5.10-i386/definition.rb +1 -1
- data/templates/CentOS-5.10-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-5.10-x86_64/definition.rb +1 -1
- data/templates/CentOS-5.5-i386-netboot/definition.rb +1 -1
- data/templates/CentOS-5.5-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-5.6-i386-netboot/definition.rb +1 -1
- data/templates/CentOS-5.6-i386/definition.rb +1 -1
- data/templates/CentOS-5.6-x86_64-netboot-packages/definition.rb +1 -1
- data/templates/CentOS-5.6-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-5.7-i386-netboot/definition.rb +1 -1
- data/templates/CentOS-5.7-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-5.8-i386-netboot/definition.rb +1 -1
- data/templates/CentOS-5.8-i386/definition.rb +1 -1
- data/templates/CentOS-5.8-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-5.8-x86_64-reallyminimal/definition.rb +1 -1
- data/templates/CentOS-5.8-x86_64/definition.rb +1 -1
- data/templates/CentOS-5.9-i386-netboot/definition.rb +1 -1
- data/templates/CentOS-5.9-i386/definition.rb +1 -1
- data/templates/CentOS-5.9-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-5.9-x86_64/definition.rb +1 -1
- data/templates/CentOS-6.0-i386-netboot/definition.rb +1 -1
- data/templates/CentOS-6.0-i386/definition.rb +1 -1
- data/templates/CentOS-6.0-x86_64-minimal/definition.rb +1 -1
- data/templates/CentOS-6.0-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-6.0-x86_64/definition.rb +1 -1
- data/templates/CentOS-6.1-x86_64-minimal/definition.rb +1 -1
- data/templates/CentOS-6.1-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-6.2-i386-minimal/definition.rb +1 -1
- data/templates/CentOS-6.2-x86_64-minimal/definition.rb +1 -1
- data/templates/CentOS-6.2-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-6.3-i386-minimal/definition.rb +1 -1
- data/templates/CentOS-6.3-x86_64-minimal/definition.rb +1 -1
- data/templates/CentOS-6.3-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-6.3-x86_64-reallyminimal/definition.rb +1 -1
- data/templates/CentOS-6.4-i386-minimal/definition.rb +1 -1
- data/templates/CentOS-6.4-i386-netboot/definition.rb +1 -1
- data/templates/CentOS-6.4-x86_64-minimal/definition.rb +1 -1
- data/templates/CentOS-6.4-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-6.5-i386-minimal/definition.rb +1 -1
- data/templates/CentOS-6.5-i386-netboot/definition.rb +1 -1
- data/templates/CentOS-6.5-x86_64-minimal/definition.rb +1 -1
- data/templates/CentOS-6.5-x86_64-netboot/definition.rb +1 -1
- data/templates/CentOS-7.0-1406-x86_64-netinstall/definition.rb +1 -1
- data/templates/Debian-5.0.10-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-5.0.10-i386-netboot/definition.rb +1 -1
- data/templates/Debian-5.0.8-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-5.0.8-i386-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.3-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.3-i386-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.4-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.4-i386-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.5-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.5-i386-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.6-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.6-i386-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.7-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.7-i386-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.8-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.8-i386-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.9-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-6.0.9-i386-netboot/definition.rb +1 -1
- data/templates/Debian-7.0-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-7.0-i386-netboot/definition.rb +1 -1
- data/templates/Debian-7.1.0-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-7.1.0-i386-netboot/definition.rb +1 -1
- data/templates/Debian-7.2.0-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-7.2.0-i386-netboot/definition.rb +1 -1
- data/templates/Debian-7.3.0-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-7.3.0-i386-netboot/definition.rb +1 -1
- data/templates/Debian-7.4.0-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-7.4.0-i386-netboot/definition.rb +1 -1
- data/templates/Debian-7.5.0-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-7.5.0-i386-netboot/definition.rb +1 -1
- data/templates/Debian-7.6.0-amd64-netboot/definition.rb +1 -1
- data/templates/Debian-7.6.0-i386-netboot/definition.rb +1 -1
- data/templates/Fedora-14-amd64-netboot/definition.rb +1 -1
- data/templates/Fedora-14-amd64/definition.rb +1 -1
- data/templates/Fedora-14-i386-netboot/definition.rb +1 -1
- data/templates/Fedora-14-i386/definition.rb +1 -1
- data/templates/Fedora-15-i386-netboot/definition.rb +1 -1
- data/templates/Fedora-15-i386/definition.rb +1 -1
- data/templates/Fedora-15-x86_64-netboot/definition.rb +1 -1
- data/templates/Fedora-15-x86_64/definition.rb +1 -1
- data/templates/Fedora-16-i386/definition.rb +1 -1
- data/templates/Fedora-16-x86_64-netboot/definition.rb +1 -1
- data/templates/Fedora-16-x86_64/definition.rb +1 -1
- data/templates/Fedora-17-i386/definition.rb +1 -1
- data/templates/Fedora-17-x86_64/definition.rb +1 -1
- data/templates/Fedora-18-i386/definition.rb +1 -1
- data/templates/Fedora-18-x86_64/definition.rb +1 -1
- data/templates/Fedora-19-i386/definition.rb +1 -1
- data/templates/Fedora-19-x86_64/definition.rb +1 -1
- data/templates/Fedora-20-i386/definition.rb +1 -1
- data/templates/Fedora-20-x86_64/definition.rb +1 -1
- data/templates/OracleLinux-5.10-i386-DVD/definition.rb +1 -1
- data/templates/OracleLinux-5.10-x86_64-DVD/definition.rb +1 -1
- data/templates/OracleLinux-5.9-i386-DVD/definition.rb +1 -1
- data/templates/OracleLinux-5.9-x86_64-DVD/definition.rb +1 -1
- data/templates/OracleLinux-6.3-x86_64-DVD/definition.rb +1 -1
- data/templates/OracleLinux-6.4-i386-DVD/definition.rb +1 -1
- data/templates/OracleLinux-6.4-x86_64-DVD/definition.rb +1 -1
- data/templates/OracleLinux-6.5-i386-DVD/definition.rb +1 -1
- data/templates/OracleLinux-6.5-x86_64-DVD/definition.rb +1 -1
- data/templates/OracleLinux-7.0-x86_64-DVD/definition.rb +1 -1
- data/templates/SLES-11-SP1-DVD-i586-GM/definition.rb +1 -1
- data/templates/SLES-11-SP1-DVD-x86_64-GM/definition.rb +1 -1
- data/templates/SLES-11-SP2-DVD-x86_64-GM/definition.rb +1 -1
- data/templates/SLES-11-SP3-DVD-x86_64-GM/definition.rb +1 -1
- data/templates/Sysrescuecd-2.0.0-experimental/definition.rb +1 -1
- data/templates/VMware-ESXi-5.0u2-x86_64/definition.rb +1 -1
- data/templates/VMware-ESXi-5.1-x86_64/definition.rb +1 -1
- data/templates/archlinux-i386/definition.rb +1 -1
- data/templates/freebsd-10.0-RELEASE-amd64/definition.rb +1 -1
- data/templates/freebsd-8.2-experimental/definition.rb +1 -1
- data/templates/freebsd-8.2-pcbsd-amd64/definition.rb +1 -1
- data/templates/freebsd-8.2-pcbsd-i386-netboot/definition.rb +1 -1
- data/templates/freebsd-8.2-pcbsd-i386/definition.rb +1 -1
- data/templates/freebsd-9.0-RELEASE-amd64/definition.rb +1 -1
- data/templates/freebsd-9.1-RELEASE-amd64/definition.rb +1 -1
- data/templates/freebsd-9.2-RELEASE-amd64/definition.rb +1 -1
- data/templates/gentoo-latest-amd64/definition.rb +1 -1
- data/templates/gentoo-latest-i686/definition.rb +1 -1
- data/templates/netbsd-613-amd64/definition.rb +1 -1
- data/templates/openSUSE-11.4-DVD-i586/definition.rb +1 -1
- data/templates/openSUSE-11.4-DVD-x86_64/definition.rb +1 -1
- data/templates/openSUSE-11.4-NET-i586/definition.rb +1 -1
- data/templates/openSUSE-11.4-NET-x86_64/definition.rb +1 -1
- data/templates/openSUSE-12.1-DVD+NET-i586/definition.rb +1 -1
- data/templates/openSUSE-12.1-DVD+NET-x86_64/definition.rb +1 -1
- data/templates/openSUSE-12.3-x86_64-NET_EN/definition.rb +1 -1
- data/templates/openSUSE-13.1/definition.rb +1 -1
- data/templates/openbsd50_amd64/definition.rb +1 -1
- data/templates/openbsd50_i386/definition.rb +1 -1
- data/templates/openbsd52_amd64/definition.rb +1 -1
- data/templates/openbsd52_i386/definition.rb +1 -1
- data/templates/openbsd52_i386_snap/definition.rb +1 -1
- data/templates/openbsd53_amd64/definition.rb +1 -1
- data/templates/openbsd53_i386/definition.rb +1 -1
- data/templates/openbsd54_amd64/definition.rb +1 -1
- data/templates/openbsd54_i386/definition.rb +1 -1
- data/templates/openbsd55_amd64/definition.rb +1 -1
- data/templates/openbsd55_i386/definition.rb +1 -1
- data/templates/openindiana-148-ai-x86/definition.rb +1 -1
- data/templates/openindiana-151a7-text-x86/definition.rb +1 -1
- data/templates/opensuse-11.4-i386-experimental/definition.rb +1 -1
- data/templates/scientificlinux-5.7-i386/definition.rb +1 -1
- data/templates/scientificlinux-5.7-x86_64/definition.rb +1 -1
- data/templates/scientificlinux-5.9-i386/definition.rb +1 -1
- data/templates/scientificlinux-5.9-x86_64/definition.rb +1 -1
- data/templates/scientificlinux-6.1-i386-netboot/definition.rb +1 -1
- data/templates/scientificlinux-6.1-x86_64-netboot/definition.rb +1 -1
- data/templates/scientificlinux-6.2-i386-netboot/definition.rb +1 -1
- data/templates/scientificlinux-6.2-x86_64-netboot/definition.rb +1 -1
- data/templates/scientificlinux-6.3-i386-netboot/definition.rb +1 -1
- data/templates/scientificlinux-6.3-x86_64-netboot/definition.rb +1 -1
- data/templates/scientificlinux-6.4-i386-netboot/definition.rb +1 -1
- data/templates/scientificlinux-6.4-x86_64-netboot/definition.rb +1 -1
- data/templates/scientificlinux-6.5-i386-netboot/definition.rb +1 -1
- data/templates/scientificlinux-6.5-x86_64-netboot/definition.rb +1 -1
- data/templates/solaris-11-express-i386/definition.rb +1 -1
- data/templates/ubuntu-10.04.2-amd64-netboot/definition.rb +1 -1
- data/templates/ubuntu-10.04.2-server-i386-netboot/definition.rb +1 -1
- data/templates/ubuntu-10.04.3-server-i386/definition.rb +1 -1
- data/templates/ubuntu-10.04.4-server-amd64-netboot/definition.rb +1 -1
- data/templates/ubuntu-10.04.4-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-10.04.4-server-i386-netboot/definition.rb +1 -1
- data/templates/ubuntu-10.04.4-server-i386/definition.rb +1 -1
- data/templates/ubuntu-10.10-server-amd64-netboot/definition.rb +1 -1
- data/templates/ubuntu-10.10-server-i386-netboot/definition.rb +1 -1
- data/templates/ubuntu-10.10-server-i386/definition.rb +1 -1
- data/templates/ubuntu-11.04-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-11.04-server-i386/definition.rb +1 -1
- data/templates/ubuntu-11.10-server-amd64-ishaya/definition.rb +1 -1
- data/templates/ubuntu-11.10-server-amd64-ruby192/definition.rb +1 -1
- data/templates/ubuntu-11.10-server-amd64-rvm/definition.rb +1 -1
- data/templates/ubuntu-11.10-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-11.10-server-i386/definition.rb +1 -1
- data/templates/ubuntu-12.04.1-server-amd64-packages/definition.rb +1 -1
- data/templates/ubuntu-12.04.1-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-12.04.1-server-i386-packages/definition.rb +1 -1
- data/templates/ubuntu-12.04.1-server-i386/definition.rb +1 -1
- data/templates/ubuntu-12.04.2-desktop-amd64/definition.rb +1 -1
- data/templates/ubuntu-12.04.2-server-amd64-netboot/definition.rb +1 -1
- data/templates/ubuntu-12.04.2-server-amd64-packages/definition.rb +1 -1
- data/templates/ubuntu-12.04.2-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-12.04.2-server-i386-netboot/definition.rb +1 -1
- data/templates/ubuntu-12.04.2-server-i386-packages/definition.rb +1 -1
- data/templates/ubuntu-12.04.2-server-i386/definition.rb +1 -1
- data/templates/ubuntu-12.04.3-desktop-i386/definition.rb +1 -1
- data/templates/ubuntu-12.04.3-server-amd64-parallels/definition.rb +1 -1
- data/templates/ubuntu-12.04.3-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-12.04.3-server-i386/definition.rb +1 -1
- data/templates/ubuntu-12.04.4-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-12.04.4-server-i386/definition.rb +1 -1
- data/templates/ubuntu-12.10-desktop-amd64/definition.rb +1 -1
- data/templates/ubuntu-12.10-server-amd64-packages/definition.rb +1 -1
- data/templates/ubuntu-12.10-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-12.10-server-i386-packages/definition.rb +1 -1
- data/templates/ubuntu-12.10-server-i386/definition.rb +1 -1
- data/templates/ubuntu-13.04-minimal-i386-rvm/definition.rb +1 -1
- data/templates/ubuntu-13.04-server-amd64-rvm/definition.rb +1 -1
- data/templates/ubuntu-13.04-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-13.10-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-14.04-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-8.04.4-server-amd64/definition.rb +1 -1
- data/templates/ubuntu-8.04.4-server-i386/definition.rb +1 -1
- data/templates/windows-2008R1-serverstandard-amd64/definition.rb +4 -5
- data/templates/windows-2008R1-serverweb-amd64/definition.rb +5 -6
- data/templates/windows-2008R1-serverweb-i386/definition.rb +5 -6
- data/templates/windows-2008R1-serverwebcore-amd64/definition.rb +5 -6
- metadata +2 -8
- data/lib/veewee/provider/kvm/box/helper/ssh_options.rb +0 -13
- data/lib/veewee/provider/kvm/box/helper/winrm_options.rb +0 -13
- data/lib/veewee/provider/parallels/box/helper/ssh_options.rb +0 -14
- data/lib/veewee/provider/parallels/box/helper/winrm_options.rb +0 -13
- data/lib/veewee/provider/vmfusion/box/helper/ssh_options.rb +0 -14
- data/lib/veewee/provider/vmfusion/box/helper/winrm_options.rb +0 -13
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
YzM2NTRjOTM1ODExZDQ4OWI1NjU1ZTk5ZWVhMzViNGIwNDA4ZGE0Mw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
YzM0MDk2Y2IxYzFiNjU3NGRiNGU3NmM0YzcxZTA2M2FhNzU4YTc4Zg==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
ZGQ4M2I3ZDY3MWQyMWIyNmQ2MThkMTllMjk2YWI1ZDcyMjE5OTczZjJjY2Q5
|
10
|
+
MzAyN2Q1ZTBkN2Q1MDgzMzBhODVlNmZiNDdlYzQyYTkzMjcxMDRhMTJhODhh
|
11
|
+
MjU3MjJlZGYwZGE0OTFlOWRmZTMxZmFlOGI4N2Y3MDhlN2VhZTQ=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
NzMxYjkxY2YyMjA2NzBiZmZjYjJmNzczYWRjMzJjYThiZjUyYTIyMWQyNWRh
|
14
|
+
NzZkMjQ4ZTdkNzE3YjZlMWQ3NTdmYzI4NGQzNWVmZjQzODc1NDViYmFmYWI0
|
15
|
+
N2JhNDVmYzE2NmU2OGI0OGJjMjczMjEzZmIzMzdkOTBlZDMzYmU=
|
data/doc/basics.md
CHANGED
@@ -14,8 +14,8 @@ Each template folder name follows a naming scheme to help you choosing the right
|
|
14
14
|
For example, the template for a Ubuntu 12.10 server (i386) basebox looks like this:
|
15
15
|
|
16
16
|
ubuntu-12.10-server-i386[-netboot]
|
17
|
-
^ ^ ^ ^
|
18
|
-
| | | +----- install flavor
|
17
|
+
^ ^ ^ ^
|
18
|
+
| | | +----- install flavor
|
19
19
|
| | +----- architecture
|
20
20
|
| +----- version
|
21
21
|
+----- OS name
|
@@ -97,9 +97,9 @@ Or you can remove the folder under `definitions`:
|
|
97
97
|
|
98
98
|
## Manage ISO files
|
99
99
|
|
100
|
-
The distro ISOs (also called *disk images*) provide all files needed to install the OS. This file is essential for starting the installation process.
|
100
|
+
The distro ISOs (also called *disk images*) provide all files needed to install the OS. This file is essential for starting the installation process.
|
101
101
|
|
102
|
-
If you already have an `.iso` file for the desired distribution on your disk, put it inside the `iso/` directory and make sure `definition.rb` is referencing the correct file.
|
102
|
+
If you already have an `.iso` file for the desired distribution on your disk, put it inside the `iso/` directory and make sure `definition.rb` is referencing the correct file.
|
103
103
|
|
104
104
|
If an expected ISO is not found in the `iso/` directory, Veewee will ask you to download the ISO file from the web. Depending on your internet connection fetching an ISO file can take a while.
|
105
105
|
|
@@ -113,7 +113,7 @@ In order to build the defined box, execute this subcommand:
|
|
113
113
|
The `build` subcommand can take the following optional flags:
|
114
114
|
|
115
115
|
Flag Option | Description
|
116
|
-
--------------------------------|-------------
|
116
|
+
--------------------------------|-------------
|
117
117
|
-f --force | overwrites if already exists
|
118
118
|
-a --auto | automatically downloads the ISO without asking
|
119
119
|
-n --nogui | builds in the background rather than opening a VM GUI and building in the GUI window
|
@@ -133,7 +133,7 @@ The `build` subcommand will run the following routines behind the scenes:
|
|
133
133
|
* Mount the ISO file `:iso_file`
|
134
134
|
* Boot up the machine and wait for `:boot_time`
|
135
135
|
* Send the keystrokes in `:boot_cmd_sequence`
|
136
|
-
* Start up a webserver on `:kickstart_port` to wait for a request
|
136
|
+
* Start up a webserver on `:kickstart_port` to wait `:kickstart_timeout` for a request for the `:kickstart_file`
|
137
137
|
IMPORTANT: Do NOT navigate to the file in your browser or the server will stop and the installer will not be able to find your preseed
|
138
138
|
* Wait for ssh login to work with `:ssh_user` and `:ssh_password`
|
139
139
|
* `sudo` execute the `:postinstall_files`
|
@@ -198,7 +198,7 @@ Validation is highly recommended before requesting a fork pull on any modified t
|
|
198
198
|
|
199
199
|
Finally let's export the box so it can be distributed or used by Vagrant:
|
200
200
|
|
201
|
-
$ bundle exec veewee vbox export 'myubuntubox'
|
201
|
+
$ bundle exec veewee vbox export 'myubuntubox'
|
202
202
|
|
203
203
|
|
204
204
|
## Up Next
|
data/doc/customize.md
CHANGED
@@ -92,7 +92,7 @@ All other settings are used internally by Veewee, the virtualization provider, o
|
|
92
92
|
'initrd=/install/initrd.gz -- <Enter>'
|
93
93
|
],
|
94
94
|
:kickstart_port => "7122",
|
95
|
-
:kickstart_timeout => "
|
95
|
+
:kickstart_timeout => "60",
|
96
96
|
:kickstart_file => "preseed.cfg",
|
97
97
|
:ssh_login_timeout => "10000",
|
98
98
|
:ssh_user => "vagrant",
|
@@ -128,7 +128,6 @@ Definition Option | Default | Provider
|
|
128
128
|
:boot_wait | uninitialised | core
|
129
129
|
:boot_cmd_sequence | empty | core
|
130
130
|
:kickstart_port | uninitialised | core
|
131
|
-
:kickstart_ip | uninitialised | core
|
132
131
|
:kickstart_timeout | uninitialised | core
|
133
132
|
:kickstart_file | uninitialised | core
|
134
133
|
:ssh_login_timeout | uninitialised | kvm, parallels, virtualbox, vmfusion
|
data/lib/veewee/definition.rb
CHANGED
@@ -21,7 +21,7 @@ module Veewee
|
|
21
21
|
|
22
22
|
attr_accessor :boot_wait, :boot_cmd_sequence
|
23
23
|
|
24
|
-
attr_accessor :kickstart_port, :
|
24
|
+
attr_accessor :kickstart_port, :kickstart_timeout, :kickstart_file
|
25
25
|
|
26
26
|
attr_accessor :ssh_login_timeout, :ssh_user, :ssh_password, :ssh_key, :ssh_host_port, :ssh_guest_port
|
27
27
|
|
@@ -92,7 +92,7 @@ module Veewee
|
|
92
92
|
# :hostiocache => 'off' ,
|
93
93
|
# :os_type_id => 'Ubuntu',
|
94
94
|
# :boot_wait => "10", :boot_cmd_sequence => [ "boot"],
|
95
|
-
# :kickstart_port => "7122", :
|
95
|
+
# :kickstart_port => "7122", :kickstart_timeout => 60,#
|
96
96
|
# :ssh_login_timeout => "10000", :ssh_user => "vagrant", :ssh_password => "vagrant",:ssh_key => "",
|
97
97
|
@ssh_host_port = "2222" ; @ssh_guest_port = "22"
|
98
98
|
# :ssh_host_port => "2222", :ssh_guest_port => "22", :sudo_cmd => "echo '%p'|sudo -S sh '%f'",
|
@@ -72,10 +72,12 @@ module Veewee
|
|
72
72
|
})
|
73
73
|
|
74
74
|
# Type the boot sequence
|
75
|
+
t =
|
75
76
|
Thread.new do
|
76
77
|
self.console_type(boot_sequence)
|
77
78
|
run_hook(:after_boot_sequence)
|
78
79
|
end
|
80
|
+
t.abort_on_exception = true
|
79
81
|
|
80
82
|
self.handle_kickstart(options)
|
81
83
|
end
|
@@ -221,34 +223,30 @@ module Veewee
|
|
221
223
|
# It requires a definition to find all the necessary information
|
222
224
|
def handle_kickstart(options)
|
223
225
|
|
224
|
-
|
225
|
-
kickstartfiles=definition.kickstart_file
|
226
|
+
case definition.kickstart_file
|
227
|
+
when Array then kickstartfiles = definition.kickstart_file
|
228
|
+
when String then kickstartfiles = definition.kickstartfiles.split
|
229
|
+
when nil then kickstartfiles = []
|
230
|
+
else raise "Do not know how to handle kickstart_file: #{kickstart_file.inspect}"
|
231
|
+
end
|
226
232
|
|
227
|
-
if kickstartfiles.
|
233
|
+
if kickstartfiles.empty?
|
228
234
|
env.ui.info "Skipping webserver as no kickstartfile was specified"
|
229
235
|
else
|
230
|
-
env.ui.info "Starting a webserver #{
|
231
|
-
|
232
|
-
|
233
|
-
# Check if the kickstart is an array or a single string
|
234
|
-
if kickstartfiles.is_a?(String)
|
235
|
-
# Let's turn it into an array
|
236
|
-
kickstartfiles=kickstartfiles.split
|
236
|
+
env.ui.info "Starting a webserver #{host_ip_as_seen_by_guest}:#{definition.kickstart_port}, check your firewall if nothing happens\n"
|
237
|
+
timeouts = Array(definition.kickstart_timeout).map(&:to_i)
|
237
238
|
end
|
238
239
|
|
239
240
|
# For each kickstart file spinup a webserver and wait for the file to be fetched
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
}
|
250
|
-
)
|
251
|
-
end
|
241
|
+
kickstartfiles.each_with_index do |kickfile, index|
|
242
|
+
wait_for_http_request(
|
243
|
+
File.join(definition.path, kickfile),
|
244
|
+
kickfile.start_with?('/') ? kickfile : '/' + kickfile,
|
245
|
+
{
|
246
|
+
:port => definition.kickstart_port,
|
247
|
+
:timeout => timeouts.fetch(index, timeouts.last), # get the matching kickfile timeout or the last defined
|
248
|
+
}
|
249
|
+
)
|
252
250
|
end
|
253
251
|
end
|
254
252
|
|
@@ -5,8 +5,14 @@ module Veewee
|
|
5
5
|
|
6
6
|
def copy_to_box(localfile,remotefile,options={})
|
7
7
|
raise Veewee::Error,"Box is not running" unless self.running?
|
8
|
-
if
|
8
|
+
if
|
9
|
+
definition.winrm_user && definition.winrm_password # prefer winrm
|
10
|
+
then
|
9
11
|
self.wincp(localfile,remotefile,options)
|
12
|
+
elsif
|
13
|
+
definition.os_type_id =~ /^Windows/
|
14
|
+
then
|
15
|
+
raise "Trying to transfer #{localfile} to windows machine without 'winrm_user' and 'winrm_password' set in definition."
|
10
16
|
else
|
11
17
|
self.scp(localfile,remotefile,options)
|
12
18
|
end
|
@@ -12,26 +12,25 @@ module Veewee
|
|
12
12
|
def vnc_type(sequence,host,display=20)
|
13
13
|
counter=0
|
14
14
|
env.logger.info "Opening VNC #{host} on display #{display}"
|
15
|
-
|
16
|
-
|
17
|
-
|
15
|
+
Net::VNC.open("#{host}:#{display}",{:wait => 0.001}) do |vnc|
|
16
|
+
sequence.each { |s|
|
17
|
+
counter=counter+1
|
18
18
|
|
19
|
-
|
19
|
+
ui.info "Typing:[#{counter}]: "+s
|
20
20
|
|
21
|
-
|
21
|
+
keycodes=string_to_vnccode(s)
|
22
22
|
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
23
|
+
keycodes.each do |keycode|
|
24
|
+
if keycode==:wait
|
25
|
+
sleep 1
|
26
|
+
else
|
27
|
+
send_vnc_keycode(vnc,keycode)
|
28
|
+
end
|
28
29
|
end
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
ui.info ""
|
34
|
-
|
30
|
+
}
|
31
|
+
ui.info "Done typing."
|
32
|
+
ui.info ""
|
33
|
+
end
|
35
34
|
end
|
36
35
|
|
37
36
|
def send_vnc_keycode(vnc,keycode)
|
@@ -48,7 +47,7 @@ module Veewee
|
|
48
47
|
|
49
48
|
def string_to_vnccode(thestring)
|
50
49
|
|
51
|
-
|
50
|
+
# https://github.com/aquasync/ruby-vnc/blob/master/data/keys.yaml
|
52
51
|
|
53
52
|
special=Hash.new
|
54
53
|
# Specific veewee
|
@@ -32,11 +32,10 @@ module Veewee
|
|
32
32
|
urlpath,
|
33
33
|
{
|
34
34
|
:port => definition.kickstart_port,
|
35
|
-
:host => definition.kickstart_ip,
|
36
35
|
:timeout => definition.kickstart_timeout,
|
37
36
|
}
|
38
37
|
)
|
39
|
-
|
38
|
+
|
40
39
|
begin
|
41
40
|
self.when_winrm_login_works(self.ip_address,winrm_options.merge(options)) do
|
42
41
|
env.ui.info "Going to try and copy #{localfile} to #{remotefile.inspect}"
|
@@ -23,7 +23,8 @@ module Veewee
|
|
23
23
|
response['Content-Type']='text/plain'
|
24
24
|
response.status = 200
|
25
25
|
content = File.open(@localfile, "r").read
|
26
|
-
response.body =
|
26
|
+
response.body =
|
27
|
+
case File.extname(@localfile)
|
27
28
|
when ".erb"
|
28
29
|
ui.info "Rendering and serving file #{@localfile}"
|
29
30
|
ERB.new(content).result(binding)
|
@@ -47,34 +48,38 @@ module Veewee
|
|
47
48
|
|
48
49
|
def allow_for_http_request(filename, urlname, options) # start in new thread
|
49
50
|
s = server_for_http_request(filename, urlname, options.merge({:threaded => false}))
|
50
|
-
Thread.new { s.start }
|
51
|
+
t = Thread.new { s.start }
|
52
|
+
t.abort_on_exception = true
|
51
53
|
end
|
52
54
|
|
53
|
-
def server_for_http_request(filename, urlname, options
|
55
|
+
def server_for_http_request(filename, urlname, options)
|
54
56
|
# Calculate the OS equivalent of /dev/null , on windows this is NUL:
|
55
57
|
# http://www.ruby-forum.com/topic/115472
|
56
58
|
fn = test(?e, '/dev/null') ? '/dev/null' : 'NUL:'
|
59
|
+
webrick_logger = WEBrick::Log.new(fn, WEBrick::Log::INFO)
|
57
60
|
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
61
|
+
timeout = options[:timeout] || 60
|
62
|
+
server = nil
|
63
|
+
Timeout.timeout(timeout) do
|
64
|
+
server =
|
65
|
+
::WEBrick::HTTPServer.new(
|
66
|
+
:Port => options[:port],
|
67
|
+
:Logger => webrick_logger,
|
68
|
+
:AccessLog => webrick_logger
|
69
|
+
)
|
70
|
+
env.logger.debug("mounting file #{urlname}")
|
71
|
+
server.mount("#{urlname}", Veewee::Provider::Core::Helper::Servlet::FileServlet, filename, ui, options[:threaded])
|
72
|
+
trap("INT"){
|
73
|
+
server.shutdown
|
74
|
+
ui.info "Stopping webserver"
|
75
|
+
exit
|
76
|
+
}
|
77
|
+
end
|
78
|
+
rescue Timeout::Error
|
79
|
+
server.shutdown unless server.nil?
|
80
|
+
raise "File #{filename.inspect} was not requested in #{timeout}seconds, are you using firewall blocking connections to port: #{options[:port]}?"
|
77
81
|
end
|
82
|
+
|
78
83
|
end #Class
|
79
84
|
end #Module
|
80
85
|
end #Module
|
@@ -11,7 +11,6 @@ require 'veewee/provider/kvm/box/destroy'
|
|
11
11
|
require 'veewee/provider/kvm/box/export_vagrant'
|
12
12
|
|
13
13
|
require 'veewee/provider/kvm/box/helper/ip'
|
14
|
-
require 'veewee/provider/kvm/box/helper/ssh_options'
|
15
14
|
require 'veewee/provider/kvm/box/helper/status'
|
16
15
|
require 'veewee/provider/kvm/box/helper/console_type'
|
17
16
|
|
@@ -6,6 +6,11 @@ module Veewee
|
|
6
6
|
def up(options={})
|
7
7
|
matched_servers=@connection.servers.all(:name => name)
|
8
8
|
matched_servers.first.start unless matched_servers.nil?
|
9
|
+
rescue Libvirt::Error => e
|
10
|
+
warn "
|
11
|
+
Libvirt Error! Make sure your user has permissions to run anything.
|
12
|
+
"
|
13
|
+
raise e
|
9
14
|
end
|
10
15
|
|
11
16
|
end # End Module
|
@@ -3,7 +3,6 @@ require 'veewee/provider/core/helper/tcp'
|
|
3
3
|
|
4
4
|
require 'veewee/provider/parallels/box/helper/status'
|
5
5
|
require 'veewee/provider/parallels/box/helper/ip'
|
6
|
-
require 'veewee/provider/parallels/box/helper/ssh_options'
|
7
6
|
require 'veewee/provider/parallels/box/helper/console_type'
|
8
7
|
require 'veewee/provider/parallels/box/helper/buildinfo'
|
9
8
|
|
@@ -4,8 +4,6 @@ require 'veewee/provider/core/helper/tcp'
|
|
4
4
|
|
5
5
|
require 'veewee/provider/vmfusion/box/helper/status'
|
6
6
|
require 'veewee/provider/vmfusion/box/helper/ip'
|
7
|
-
require 'veewee/provider/vmfusion/box/helper/ssh_options'
|
8
|
-
require 'veewee/provider/vmfusion/box/helper/winrm_options'
|
9
7
|
require 'veewee/provider/vmfusion/box/helper/vnc'
|
10
8
|
require 'veewee/provider/vmfusion/box/helper/console_type'
|
11
9
|
require 'veewee/provider/vmfusion/box/helper/buildinfo'
|
data/lib/veewee/version.rb
CHANGED
@@ -5,7 +5,7 @@ Veewee::Definition.declare({
|
|
5
5
|
:iso_file => "CentOS-4.8-i386-bin-DVD.iso", :iso_src => "", :iso_md5 => "", :iso_download_timeout => 1000,
|
6
6
|
:iso_download_instructions => "This iso is no more available, for instructions see http://vault.centos.org/4.8/isos/i386/",
|
7
7
|
:boot_wait => "10", :boot_cmd_sequence => [ 'linux text ks=http://%IP%:%PORT%/ks.cfg<Enter>' ],
|
8
|
-
:kickstart_port => "7122", :kickstart_timeout =>
|
8
|
+
:kickstart_port => "7122", :kickstart_timeout => 300, :kickstart_file => "ks.cfg",
|
9
9
|
:ssh_login_timeout => "10000", :ssh_user => "vagrant", :ssh_password => "vagrant", :ssh_key => "",
|
10
10
|
:ssh_host_port => "7222", :ssh_guest_port => "22",
|
11
11
|
:sudo_cmd => "echo '%p'|sudo -S sh '%f'",
|
@@ -18,7 +18,7 @@ Veewee::Session.declare({
|
|
18
18
|
:boot_wait => "10",
|
19
19
|
:boot_cmd_sequence => [ 'linux text ks=http://%IP%:%PORT%/ks.cfg<Enter>' ],
|
20
20
|
:kickstart_port => "7122",
|
21
|
-
:kickstart_timeout =>
|
21
|
+
:kickstart_timeout => 300,
|
22
22
|
:kickstart_file => "ks.cfg",
|
23
23
|
:ssh_login_timeout => "10000",
|
24
24
|
:ssh_user => "vagrant",
|
@@ -18,7 +18,7 @@ Veewee::Session.declare({
|
|
18
18
|
:boot_wait => "10",
|
19
19
|
:boot_cmd_sequence => [ 'linux text ks=http://%IP%:%PORT%/ks.cfg<Enter>' ],
|
20
20
|
:kickstart_port => "7122",
|
21
|
-
:kickstart_timeout =>
|
21
|
+
:kickstart_timeout => 300,
|
22
22
|
:kickstart_file => "ks.cfg",
|
23
23
|
:ssh_login_timeout => "10000",
|
24
24
|
:ssh_user => "vagrant",
|
@@ -18,7 +18,7 @@ Veewee::Session.declare({
|
|
18
18
|
:boot_wait => "10",
|
19
19
|
:boot_cmd_sequence => [ 'linux text ks=http://%IP%:%PORT%/ks.cfg<Enter>' ],
|
20
20
|
:kickstart_port => "7122",
|
21
|
-
:kickstart_timeout =>
|
21
|
+
:kickstart_timeout => 300,
|
22
22
|
:kickstart_file => "ks.cfg",
|
23
23
|
:ssh_login_timeout => "10000",
|
24
24
|
:ssh_user => "vagrant",
|
@@ -18,7 +18,7 @@ Veewee::Session.declare({
|
|
18
18
|
:boot_wait => "10",
|
19
19
|
:boot_cmd_sequence => [ 'linux text ks=http://%IP%:%PORT%/ks.cfg<Enter>' ],
|
20
20
|
:kickstart_port => "7122",
|
21
|
-
:kickstart_timeout =>
|
21
|
+
:kickstart_timeout => 300,
|
22
22
|
:kickstart_file => "ks.cfg",
|
23
23
|
:ssh_login_timeout => "10000",
|
24
24
|
:ssh_user => "vagrant",
|