gryf
c19f4f1a61
Update devstack deployment examples.
2021-08-20 08:24:50 +02:00
gryf
d7544f52f6
Added run type option to create and rebuild subcommand.
...
For now, the only mode VirtualBox VM has launched was headless. For
debugging purposes, there were other types allowed using --type switch
for command create and rebuild, while headless will remain the default
one.
2021-08-19 21:09:06 +02:00
gryf
3c43263bb9
Fix clashing version from boxpy and subcommands.
...
Currently, you could pass long version of '--version' option to either
boxpy itself and subcommands create and rebuild. With this patch proper
context is now detected.
2021-08-19 21:08:34 +02:00
gryf
bd59dd378e
Added boxpy --version option.
2021-08-13 11:43:33 +02:00
gryf
b2a6305728
Add user data file path to info command.
2021-08-13 11:19:34 +02:00
gryf
03b21369e3
Added new option for disabling nested virtualization.
...
By default, nested virtualization is enabled. It can be disabled by
passing --disable-nested.
2021-08-13 11:14:30 +02:00
gryf
635917faf2
Added ability to listing VMs created by boxpy
2021-07-13 15:54:13 +02:00
gryf
73803e2c4b
Fix return value for storageattach method.
2021-07-06 19:51:48 +02:00
gryf
2048455410
Fix issue with undefined port.
2021-07-06 19:50:31 +02:00
gryf
2f7a37aaed
Remove silent parameter for poweroff.
2021-07-06 19:50:06 +02:00
gryf
10d7b58ec3
Fixed minor linting issues
2021-07-06 19:48:53 +02:00
gryf
11e3c033c1
Fix for missing default config.
2021-07-05 20:00:38 +02:00
gryf
322e50a8f9
Add support for port passed ports fw.
2021-07-05 20:00:05 +02:00
gryf
e324b6771c
Pass config object to VBox.create
2021-07-05 19:58:58 +02:00
gryf
9ad861182a
Handle forwarding ports mappings in config
2021-07-05 19:45:07 +02:00
gryf
b2ef6890ba
Added option for forwarding ports.
2021-07-05 18:50:21 +02:00
gryf
c23b5f3e49
Handle multiple forwarding ports
2021-07-05 12:39:28 +02:00
gryf
e5173c707d
Fixed case when there is no user data provided.
2021-07-05 12:08:32 +02:00
gryf
be91f6b827
Removed unused variable
2021-07-05 12:07:56 +02:00
gryf
2d83519b1c
Minor logging fixes.
2021-06-30 15:31:54 +02:00
gryf
0eea78e65e
Updated readme
2021-06-30 15:31:20 +02:00
gryf
822609504d
Added info command.
2021-06-27 19:34:05 +02:00
gryf
21dc3ec2ce
Adding extra data 'creator'.
...
This field would help to distinguish if VM has been created by boxpy, or
manually.
2021-06-27 19:32:18 +02:00
gryf
ac47f126c0
Removed surplus get_vm_info call in config.
2021-06-27 19:31:32 +02:00
gryf
a975232042
Added additional parameter for get_media_size function.
2021-06-27 19:30:46 +02:00
gryf
7a9336f179
Minor fixes for logging. Removed unused exception classes.
2021-06-27 17:26:06 +02:00
gryf
d1481ea02f
Added logging messages here and there. Now it should looks better.
2021-06-27 17:17:13 +02:00
gryf
a56b76f16d
Changing approach with detecting if cloud init finished.
...
Till now, boxpy was based on the fact, that there was power_state
section, and there was a check if VM is down already. That approach have
their own issues.
Now, there will be no more power-off, there is a check by using
`cloud-init status` command through ssh.
Cleanup/destroy parts has needed some modification, so that there will
be no leftovers from cloud init ISO image.
And finally, there was some tweaks for user-data cloud-init part (mainly
for ssh handling), so that `cloud-init status` will not report phony
errors.
2021-06-26 15:48:43 +02:00
gryf
cc4b4da253
Added wrapper on subprocess.run
2021-06-26 11:13:59 +02:00
gryf
82c52030c8
Fixes for log verbosity calculations
2021-06-26 10:35:29 +02:00
gryf
ca20f8dbe3
Added colored "logging" with adjusted verbosity.
2021-06-25 20:03:18 +02:00
gryf
62a805cb00
Added examples for plain devstack deployments for Ubuntu and Fedora.
2021-06-25 16:05:57 +02:00
gryf
8b28914deb
Do not overwrite previously set options.
...
If user doesn't provide options from commandline during rebuild, such
option will be overwritten by those stored in VM XML, even if user
change such option in config file. This commit fixing that.
2021-06-20 14:30:22 +02:00
gryf
cbb0c6b5af
Change description for create/rebuild and boxpy itself.
2021-06-20 14:29:44 +02:00
gryf
0c1a757cf8
Updated kuryr multinode examples
2021-06-20 11:37:56 +02:00
gryf
9bae81a993
Removed unneeded condition.
2021-06-20 11:33:24 +02:00
gryf
f8f3d3f819
Move setting defaults to Config class.
2021-06-05 20:23:53 +02:00
gryf
cd4bc42e54
Added check for already used port.
2021-06-05 20:12:25 +02:00
gryf
5cf00a3e09
Rework port for the ssh forwarding.
...
Till now, user has to provide port number (by commandline or through
config file), otherwise 2222 will be set. That's unfortunate in case you
need to have multiple machines and forgot about setting the correct
port. In this patch random port will be used if no port is provided.
2021-06-05 19:14:49 +02:00
gryf
81da9d7c13
Added ssh command
2021-06-05 17:54:14 +02:00
gryf
3f8dec1f2d
Fix config behavior in case of empty args
2021-06-05 17:09:02 +02:00
gryf
e8264c5c69
Update readme file.
2021-06-04 18:54:56 +02:00
gryf
1a058a1e2a
Added fedora cloud to supported distros.
2021-06-04 18:39:10 +02:00
gryf
de61390d5e
Added ability to select distro. Yet, we still have only one ;)
2021-06-04 18:37:03 +02:00
gryf
d78ed6db8b
Parametrize user information
2021-06-04 16:43:06 +02:00
gryf
38e37f6274
Fixing some linting issues.
2021-06-04 16:38:00 +02:00
gryf
6e84b3befa
Process template before reading files into cloud init.
2021-05-19 19:44:30 +02:00
gryf
7647f4d021
Use OVS over OVN in kuryr devstack deployment
2021-05-17 19:16:15 +02:00
gryf
5218354e5e
Readme update
2021-05-17 19:15:32 +02:00
gryf
4a46d793cb
Parse filenames in global write_files section
2021-05-17 18:56:44 +02:00
gryf
074025c089
Make temporary files begin with meaningful prefix
2021-05-17 18:55:01 +02:00
gryf
c0e4ad966b
Add ability to write files to be written on guest by providing filename.
2021-05-14 15:07:57 +02:00
gryf
d890f28eba
Fixed bash completion for config; added default completion for all other options.
2021-05-14 14:19:00 +02:00
gryf
3b59622a68
Added warning if config file doesn't exists.
2021-05-14 13:46:15 +02:00
gryf
f6a458e1f9
Save absolute path to the user config file
2021-05-14 13:45:26 +02:00
gryf
3ebe6ff529
Changing option cloud-config to config
2021-05-14 13:44:17 +02:00
gryf
658d2bd9df
update kuryr multinode confs
2021-05-12 13:47:39 +02:00
gryf
89a87c77aa
Added wmaker build machine definition
2021-05-10 20:45:45 +02:00
gryf
e84b967d8d
Added examples.
2021-05-10 20:07:52 +02:00
gryf
a770c0bbae
Fixed typo in readme.
2021-05-06 20:53:45 +02:00
gryf
1e8bd7a37d
Do not relay on vboxmanage output.
...
There is a function which retrieve information about VM by looking on
the 'vboxmanage vminfo' command. The output wasn't consistent, yet it
was fixed recently so that amount of memory was all wrong.
Currently the only thing which is searched for is the VM configuration
path, and all the rest is taken out from the XML VM definition.
2021-05-06 20:53:36 +02:00
gryf
78d696656e
Rebuild now pass the config to the create function.
...
This will avoid overwriting all of the configuration during executing
vmcreate function, which initially doesn't know anything about existing
data - it only knows about passed through command line parameters. Now
it should be fixed.
2021-05-06 20:53:29 +02:00
gryf
6d0fa3445f
Rearranged a bit Config class.
2021-05-06 20:53:21 +02:00
gryf
b557a6353d
Added advanced feature.
...
In boxpy_data section it is possible to specify another nic and its type
to be attached to the vm:
boxpy_data:
advanced:
nic2: intnet
nic3: hostonly
It's a stub for now, and only intnet will work by providing another nic,
which user should take care about providing configuration.
2021-05-06 20:50:33 +02:00
gryf
1bded7f75c
Wait for VM to truly power off.
...
Added small sleep to wait for the machine to be truly down before
detaching ISO image.
2021-05-06 20:50:02 +02:00
gryf
30b7f1ab59
Fixed name clash on Config and VBoxManage objects.
...
There were two different things named with the same name in both
classes, which lead to conflict. This patch is fixing it.
2021-05-06 20:48:07 +02:00
gryf
8df0d31d25
Some minor tweaks
2021-05-05 20:42:39 +02:00
gryf
799efd8633
Readme update
2021-05-05 20:24:39 +02:00
gryf
91f0019c78
Added cleanup for interrupted cloud-init
2021-05-05 20:24:07 +02:00
gryf
da1ae93fa2
Added ability for merging options using all possible ways.
...
Currently specifying attributes of VM was done by using command options
during creation, or only required VM name for rebuilding (due to smart
way of storing information within VM definition).
Now, there is possibility for providing all the information using
special key "boxpy_data" in user-script, so that there is no need to
provide that information from command line.
All three ways are respected with following order:
- default, which are hard coded in defaults
- custom user script passed by --cloud-config (or stored in vm in case
of rebuild)
- information which is stored in VM definition (if exists - this only
affects "rebuild" command)
- and finally highest priority have parameters passed by command line.
2021-05-05 20:15:39 +02:00
gryf
359d1cf440
Changed user-data-path param to cloud-config
2021-05-05 17:29:21 +02:00
gryf
ed5535cd4e
Guard against interruption during invalid cloud config.
2021-05-05 17:25:59 +02:00
gryf
9da0e3f6ff
Cacluate hostname out of vm name.
2021-04-20 11:56:46 +02:00
gryf
d4afa6e90b
Added ssh port forwarding port option
2021-04-20 09:57:20 +02:00
gryf
03b6fdb8ec
Remove irrelevant options from completion
2021-04-20 09:55:12 +02:00
gryf
c51603644b
Added missing gnu sed definition and some cosmetic changes for completion script.
2021-04-13 21:44:14 +02:00
gryf
2984109bd5
Made a poor-man progress bar for waiting for cloud init.
2021-04-12 20:58:32 +02:00
gryf
05c3259c76
Changed defaults to use less resources
2021-04-12 20:57:52 +02:00
gryf
180c30c834
Fixed bug for not filles user-data option
2021-04-12 20:56:24 +02:00
gryf
198dfefeeb
Added bash completion
2021-04-12 20:55:04 +02:00
gryf
40ac14723a
Added ability to provide own user-data template
2021-04-12 19:15:51 +02:00
gryf
9b433cb044
Store information about other provided options during createion as extra data.
2021-04-12 17:35:44 +02:00
gryf
11f1ee5dda
Added ability to specify sizes in GB.
2021-04-12 17:34:02 +02:00
gryf
ca713375ea
Add missing media closing
2021-04-11 19:15:53 +02:00
gryf
06480daffb
Simplify commands by using provided abstractions.
2021-04-11 18:59:20 +02:00
gryf
b0a64a6545
Added image abstraction for downloading and converting image.
2021-04-11 18:56:45 +02:00
gryf
b05b9403c4
Added rebuild command.
2021-04-11 18:55:41 +02:00
gryf
fc0a19bf38
Added VBoxManage class for abstraction of vboxmanage calls.
2021-04-11 18:52:57 +02:00
gryf
3babb880e2
Added license file.
2021-04-10 18:49:30 +02:00
gryf
38b6e1b6af
Add possibility to just pass key name.
...
From now, it's possible to just pass the key name, not the full path to
the key. By default it will be looked for in ~/.ssh directory.
2021-04-10 16:48:57 +02:00
gryf
70248bd23b
Added list command.
2021-04-08 21:52:28 +02:00
gryf
69ff7206e5
Introducing custom exceptions tree.
2021-04-08 21:44:54 +02:00
gryf
4029284815
Added destroy class and the corresponding class.
2021-04-08 21:42:49 +02:00
gryf
59c8b926d8
Remove unneeded intermediate function for invoking action class.
2021-04-08 21:29:16 +02:00
gryf
9ee10b4042
Readme update
2021-04-08 20:19:54 +02:00
gryf
ecb9c71c5d
Added other option for mkisofs
2021-04-08 20:19:31 +02:00
gryf
0dded78bd2
Finalize build, removing cloud image, run freshly created vm.
2021-04-08 20:17:41 +02:00
gryf
3332177ab7
Adeded generating of cloud image
2021-04-08 19:34:02 +02:00
gryf
f61652a98d
Attaching media images to vm, fixing some bugs
2021-04-08 19:33:06 +02:00
gryf
8156235d7d
Create and set up VM
2021-04-07 19:35:34 +02:00