Commit graph

228 commits

Author SHA1 Message Date
Anders Ingemann
e80ad46972 Repeat index/README pattern for plugins & providers 2015-04-16 23:52:07 +02:00
Anders Ingemann
caf5d6af15 Add salt dependencies in the right phase 2015-04-16 22:22:47 +02:00
Anders Ingemann
9ad79cbf60 Remove some unnecessary dependencies across phases 2015-04-16 22:22:47 +02:00
Anders Ingemann
411578a498 *Always* use link_dm_node() when install grub 1.99
Grub install fails when in a chrooted environment,
it has nothing to do with the volume being a loopback volume
2015-04-16 22:22:47 +02:00
Anders Ingemann
a62ce1705a Remove the PartitionGap class, it's way too much of a hassle to work with
Instead pad_start and pad_end have been introduced
2015-04-16 22:21:44 +02:00
Anders Ingemann
1569797e5b Properly set the states of different partitions in prebootstrapped plugin 2015-04-16 22:21:44 +02:00
Anders Ingemann
e1946fcb68 Simpler check for whether to create image or use image in prebootstrapped plugin 2015-04-16 22:21:42 +02:00
Anders Ingemann
a476248ed6 Partition volumes by sectors instead of bytes
This allows for finer grained control over the partition sizes and gaps
2015-04-16 22:21:13 +02:00
Anders Ingemann
5823c9119b Split grub and extlinux installs into separate modules 2015-04-16 22:21:12 +02:00
Anders Ingemann
953987fddf Combine documentation from github wiki with sphinx
This is the first step in the effort of combining all documentation about
bootstrap-vz into sphinx while still being able to access it from github
(github can parse rst as well)
2015-04-11 16:40:44 +02:00
Jonh Wendell
a5cd6e077d ec2_launch: Allow to deregister the AMI after launching image
If all you want is to test an image or product and to achieve this
you need to generate several images a day, you will end up with
lots of AMI's and snapshots that have no use in the end of the day.

This commit adds the new boolean manifest option "deregister_ami"
that, if True, deletes the recently created AMI and snapshot. So, the
final result will be only the running instance, nothing else.
2015-04-06 14:23:36 -03:00
Jonh Wendell
50d61c735d ec2_launch: Store the instance object directly in the info dictionary
Instead of storing just its ID.

This gives quick access to the recently created instance, which
allows us to simplify the code that needs to fetch the instance object
every time it was necessary.
2015-04-06 14:21:13 -03:00
Jonh Wendell
b934808cce ec2_launch: Simplify the logic for getting the IP address
Use the function waituntil() available in the integration-test branch
to simplify the code that retrieves the IP of the instance.

A 'TODO' note was also added to remember us to merge this function
once it gets merged.
2015-04-06 11:47:15 -03:00
Jonh Wendell
af68be15c6 New plugin: ec2_launch
It adds the ability to automatically launch an EC2 instance
after AMI registration.

It has no mandatory configuration, only optional ones, like
instance type, security groups, etc. They should be documented in
later documentation patches.
2015-03-30 15:36:33 -03:00
Jonh Wendell
8ee0af1a3b Execute entries with a single string as shell commands
Documentation says about that, but it's not implemented like that.

If the command to be executed is an array with just one string, it's
likely the user passed the entire command inside the string.

Plus, they benefit from shell expansion of wildcards like '*'.
2015-03-27 11:23:58 -03:00
Anders Ingemann
d046c8e1f7 Merge pull request #194 from Rory-Finnegan/ansible
Added an Ansible plugin, which runs a playbook on the chroot
2015-02-22 16:56:33 +01:00
Anders Ingemann
31d61e778b Fix some more pep8 errors 2015-02-22 16:49:52 +01:00
Rory Finnegan
c372757104 Added an Ansible plugin, which runs a playbook on the chroot before before build completion.
NOTE: I'm not doing any validation on the opt_flags param and I don't recommend using for more then adding a -vvvv.
Also, I'm purposely excluding the vault flags (which also pretty commonly used) because you shouldn't be baking
private keys and certs into your images. Instead, just avoid running the vault specific code or use the
opt_flags if absolutely necessary.
2015-02-11 21:20:59 +00:00
Jonh Wendell
8418090018 Recover file permissions after shrink a vmdk image
After vmware-vdiskmanager runs, the image is left with a 600
permission. This commit fixes it by preserving the file permission
before the shrink operation.
2015-01-27 21:12:39 -02:00
Anders Ingemann
255f0624b4 Merge pull request #175 from andrewbogott/file_copy_plugin
Add the file_copy plugin
2014-12-15 15:33:32 +06:00
Andrew Bogott
81cb82a335 Fix a slightly broken plugins/puppet/manifest-schema.yml 2014-12-15 09:24:14 +00:00
Andrew Bogott
d34aeab6e0 Add the file_copy plugin
File_copy supports creation of dirs and copying of files
from the host system into the image.

bug 168
2014-12-15 09:20:02 +00:00
Dan Merino
be5da54b46 Use DOCKER_LOCKEDMEMORY to set ulimit -l before starting Docker. Very important when applications inside the containers need to lock to large amounts of memory. 2014-11-27 16:28:56 -06:00
Dan Lorenc
718ef7ed26 Fix log_check_call in docker_daemon. 2014-11-24 11:24:13 -08:00
Dan Lorenc
170ece3691 Add opts parameter to docker_daemon. 2014-11-21 17:35:57 -08:00
Johan Euphrosine
e4663f4fbe docker_daemon: add comments 2014-11-21 11:22:11 -08:00
Johan Euphrosine
141e6399f3 fix ident, raise TaskError 2014-11-21 10:51:03 -08:00
Johan Euphrosine
99786539c7 plugins/docker_daemon: flake8 2014-11-19 16:25:27 -08:00
Johan Euphrosine
e53e727c9c plugins/docker_daemon: only add PullDockerImages tasks when pull_images is set 2014-11-19 16:21:38 -08:00
Johan Euphrosine
6fdf0cc403 plugins/docker_daemon: align with space 2014-11-19 16:16:26 -08:00
Johan Euphrosine
31ba98821c plugins/docker_daemon: logcheckcall, inline pull and indent 2014-11-19 16:14:51 -08:00
Johan Euphrosine
feb4d093c9 bootstrapvz/plugins/docker_daemon: spaces to tabs 2014-11-19 11:53:23 -08:00
Johan Euphrosine
962532065c bootstrapvz/plugins/docker_daemon: flake8 2014-11-19 11:49:26 -08:00
Johan Euphrosine
f3a9a1b1ec docker_daemon: add pull_images option 2014-10-31 05:32:15 -07:00
Dave Bailey
bad378e28b fix test for DOCKER_NOFILE 2014-09-22 17:11:26 +00:00
Dave Bailey
107577cb16 allow custom ulimit -n for Docker 2014-09-17 18:12:49 +00:00
Tiago Ilieve
0f5de13bae Add version option to docker_daemon plugin
As requested on #147, there is now an option to specify the Docker
version to be installed when using the `docker_daemon` plugin. The
version string is validated against a pattern extracted from the
Docker's CHANGELOG. If the version is not present, it will just download
the latest available.

The download method was also changed from `urllib` to `wget`, so we can
see its progress if needed.

This closes #147.
2014-09-13 15:08:52 -03:00
Max Illfelder
3ff1bfb7d9 Removed a check to verify file type
The file command is not installed by bootstrap-vz by default.

Change-Id: I59d5f04145b7db517c28bfec1d4d758be468b398
2014-08-14 18:10:54 -07:00
Anders Ingemann
9f46bdc519 Merge pull request #131 from jkaplowitz/cloudsdk
Install Cloud SDK, which includes gcutil and gsutil.
2014-08-05 17:12:51 -06:00
Jimmy Kaplowitz
a352f4d576 Installing Cloud SDK which includes gcutil and gsutil. We still don't
have a package for it so laying out the tarball for now.

Change-Id: If66f0f1c074e6077e1ca57375cac9c4832bbd7fc
2014-08-01 20:05:23 -07:00
Jimmy Kaplowitz
c412c4cdcf Fix list of tasks and their ordering
- GCE provider wasn't including the GCE SetHostname task, without which
  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=604883 was
  preventing the hostname from getting set after reboot.
- During the GCE build, one of the GCE cleaning tasks was trying to run
  an apt-get update after the build-time resolv.conf file was removed.
  Fix this ordering by moving the network.Remove* tasks to the
  system_cleaning phase as they should have been all along, and adding
  an appropriate ordering rule for the GCE cleaning task.
- Add the fallback http.debian.net mirror after, not before, our mirror.
- The puppet plugin's ApplyPuppetManifest task specified that it should
  run before the network.Remove* tasks within the system_modification
  phase. Now that those tasks have been moved to a later phase
  (system_cleaning), remove this dependency. I have no puppet manifest
  to test this change, but am including it in hopes of avoiding a
  breakage there. Hopefully someone who uses puppet can test this or at
  least confirm that it's correct.

Change-Id: Ieca97f288f456bab119989f4cbc4c3993a755830
2014-07-24 20:20:54 -07:00
Anders Ingemann
f925045e59 8f43ee1d removed a used import in the cloud-init and opennebula plugins, readded 2014-07-12 19:56:18 +02:00
Tiago Ilieve
8f43ee1dc7 Move AddBackports to common.tasks.apt
The `AddBackports` task is needed by many different plugins, so is
better if it is available as a common task.

This closes #96.
2014-07-12 14:42:52 -03:00
Anders Ingemann
e4a9cc837a Differentiate installation of grub 1.99 and grub 2 2014-07-09 23:17:05 +02:00
Anders Ingemann
34bb45bb00 Factor release codename fetching out into common.tools
This allows code that runs before the bootstrapinformation object has been created
to also figure out the release codename
2014-07-09 23:17:05 +02:00
Anders Ingemann
03a0746299 Convert every JSON file to YAML
Lines removed: over 500. Readiblity gained: A shitload
Now you can actually get an overview of a manifest on a single screen height.
I am sure that it will also save a lot of hassle when modifying schema in the future.
No more "expected property name" etc. because of an extraneous comma
Comments are of course natively support, so there's no need for this minify_json hokey pokey
2014-07-09 23:17:04 +02:00
Anders Ingemann
ebba39f59b Convert "provider" into provider specific section
This is where all provider specific settings belong
like waagent on azure, guest additions iso path on vbox and virtualization type on ec2
2014-07-09 23:17:04 +02:00
Victor Marmol
fb8507c0f4 Enable the memory cgroup for the Docker plugin.
This will allow for the enforcement and tracking of memory limits and usage.
2014-06-23 19:38:38 +00:00
Ilya Margolin
669ccc3a8b Added pip_install plugin
configuration is like

"pip_install": {"packages": ["a_package", "another_package==1.0.1"]}

Installs build-essential and python-dev
2014-06-06 17:24:20 +02:00
Anders Ingemann
08c0a88459 Might as well check apt proxy early
Moved CheckAptProxy to preparation phase
Changed the logging to output a warning instead of an error
Changed the error message a little
2014-05-23 20:19:09 +02:00