Commit Graph

3233 Commits

Author SHA1 Message Date
Michael Marineau
92499b727f add(build_container): New catalyst script for buildbot containers.
Does nothing more than build a slightly larger SDK tarball right now.
2013-08-29 17:35:07 -04:00
Michael Marineau
592bc59cca add(upload_ami_txt): Upload text file that contains the AMI id. 2013-08-29 14:24:06 -07:00
Michael Marineau
693bf2f815 fix(test_ami): Fix help text. 2013-08-29 13:59:30 -07:00
Michael Marineau
753e1ea820 Merge pull request #102 from marineam/sdk-depends
fix(sdk): Use coreos-devel/sdk-depends instead of hard-host-depends
2013-08-29 08:51:31 -07:00
Brandon Philips
28a049b288 Merge pull request #100 from gregkh/efi_kernel
feat(update_bootloaders.sh) add UEFI boot support
2013-08-29 08:17:43 -07:00
Michael Marineau
b3f77e88f9 Merge pull request #101 from marineam/master
fix(test_ami): Fix assorted mistakes from last review cycle.
2013-08-28 16:30:17 -07:00
Michael Marineau
29ccafbdba fix(sdk): Use coreos-devel/sdk-depends instead of hard-host-depends
coreos-devel/sdk-depends is a super-set of hard-host-depends and has a
somewhat better name.
2013-08-28 15:59:05 -07:00
Michael Marineau
cc2587921a fix(test_ami): Fix assorted mistakes from last review cycle.
This at least gets autotest running and logging into the hosts but none
of the tests are actually executed properly yet. One step at a time..
2013-08-28 15:37:09 -07:00
Greg Kroah-Hartman
75ac767130 feat(update_bootloaders.sh) add UEFI boot support
This creates the EFI/BOOT/ directory in the boot partition and copies a
version of the kernel into there so that UEFI bioses can boot directly
into the kernel, no bootloader needed.
2013-08-28 14:24:02 -07:00
Michael Marineau
2ae25567ea Merge pull request #99 from marineam/master
fix(image_to_vm): Add missing call to check_gsutil_opts.
2013-08-28 14:12:19 -07:00
Michael Marineau
f7e15d1444 fix(image_to_vm): Add missing call to check_gsutil_opts.
The --upload_path argument was not being properly handled because this
was missing, creating lots of 54.0.0+2013-08-28-1810 style directories
instead of master. Oops.
2013-08-28 14:00:12 -07:00
Michael Marineau
1539ff334e Merge pull request #98 from marineam/image-size
Image size
2013-08-28 12:25:56 -07:00
Brandon Philips
043dfeb868 Merge pull request #94 from philips/pxe-initial
Pxe initial
2013-08-28 12:09:41 -07:00
Brandon Philips
ce445512fd fix(build_library): fixup naming for the pxe image
based on @marineam's comments fixup the naming and ensure the output
files get picked up by the build system.
2013-08-28 12:04:55 -07:00
Michael Marineau
dfb7d8d115 fix(build_library): Drop default 'base' layout to 512MB for STATE.
This will further reduce the amount of dd'ing required when using block
devices.
2013-08-28 11:55:25 -07:00
Michael Marineau
8a488f890b fix(image_to_vm): Increase STATE in vagrant images to 16GB
Vagrant users are accustomed to much larger disk sizes so lets give it
to them. I'm leaving the others as-is since it is easier to grow than
shrink disks if anyone has a particular size they need.
2013-08-28 11:52:19 -07:00
Michael Marineau
9734ac017f feat(image_to_vm): Make disk layout configurable by VM type.
Use the smaller base format for 'raw' disk images since these will
usually be dd'd to a block device to create AMIs and what not. For
images using qcow2 and vmdk stick with the larger vm size.
2013-08-28 11:35:06 -07:00
Michael Marineau
7f64629664 Merge pull request #97 from marineam/vmware
feat(image_to_vm): Add 'vmware_insecure' image type.
2013-08-28 10:18:24 -07:00
Michael Marineau
c6bbadd6e0 feat(image_to_vm): Add 'vmware_insecure' image type.
This bundles the vagrant ssh key, vmdk, and vmx into a zip file for easy
downloading and login access via ssh.
2013-08-27 21:18:12 -07:00
Brandon Philips
a840ae036c feat(build_library): pxe support
This adds support for creating a PXE image and kernel using build_image
2013-08-27 17:33:44 -07:00
Brandon Philips
c7dab1c3b9 Merge pull request #96 from marineam/user-fix
fix(make_chroot): Don't fail if user's full name is blank.
2013-08-26 16:06:13 -07:00
Michael Marineau
607c4b1cd5 fix(make_chroot): Don't fail if user's full name is blank.
It is perfectly valid for the comment field in a passwd file to be
blank so don't treat that as an error. Sorry backjlack :-/
2013-08-26 12:06:47 -04:00
Michael Marineau
309e247b9a Merge pull request #95 from marineam/sdk-on-coreos
SDK on CoreOS
2013-08-25 20:19:39 -07:00
Michael Marineau
8b7cc15bc6 Revert "fix(build_library): Create disk image first instead of last."
This reverts commit b97cfe126f.

The minor device numbers of loop partitions are allocated dynamically
which significantly complicates dunning under Docker which uses a static
/dev. Rolling this back until we can rely on /dev being dynamic.
2013-08-26 00:53:27 +00:00
Michael Marineau
4f18deb87f fix(build_image): Add support for using git in dev images.
If git is installed via coreos-dev in the STATE partition it will need
some help finding its install location since it was built thinking it
would be installed in /usr rather than /usr/local.
2013-08-26 00:53:21 +00:00
Michael Marineau
6c2f9a9ffb fix(make_chroot): Improve chroot user creation.
If the user already exists check that the UID and GID are correct and
modify it (setting shell and home directory) to match what the SDK
expects. This avoids needlessly failing if the user calling cros_sdk is
the 'core' user on a CoreOS machine.

Change new-user creation to copy the user's full name and group instead
of using a generic name and Google's 'eng' group. Also remove the
default password for the account, it isn't needed and uses perl.
2013-08-26 00:53:13 +00:00
Michael Marineau
bf0a37a0f4 fix(make_chroot): Move timezone setup to general init function.
No idea why this was in the user setup function, move it a bit.
2013-08-24 22:36:02 -04:00
Brandon Philips
84a2619829 Merge pull request #91 from doodles526/master
Add autotest tests to test_ami.sh
2013-08-22 11:26:53 -07:00
Brandon Philips
047e3e0df1 feat(build_library): put all of the partition stuff behind a flag
this lays the groundwork for supporting a cpio img which doesn't have
partitions.
2013-08-22 10:51:11 -07:00
Josh Deare
aec8cffb60 added autotest testing to test_ami 2013-08-22 10:10:34 -07:00
Michael Marineau
5bb8e6a789 Merge pull request #93 from marineam/timeout
fix(test_ami): Bump socket startup timeout to 90 seconds.
2013-08-21 21:30:04 -07:00
Michael Marineau
75c839a679 fix(test_ami): Bump socket startup timeout to 90 seconds.
I've observed networking between ec2 instances not start working for
somewhere between 40-50 seconds earlier today which caused the test to
fail despite the fact that everything came up properly eventually.
Upping to 90 seconds should better cope with the surprises Amazon has to
offer.
2013-08-22 00:13:47 -04:00
Michael Marineau
63713f2eee Merge pull request #92 from marineam/images
Lots of image building updates
2013-08-21 15:35:34 -07:00
Michael Marineau
b97cfe126f fix(build_library): Create disk image first instead of last.
This avoids the need to dd individual filesystem images into a complete
disk image, just mount the partitions directly from a loop device
covering the whole image. This does add the requirement that mkfs run as
root but that isn't a problem.
2013-08-21 16:54:23 -04:00
Michael Marineau
34cfe6e07e churn(build_library): Change lots of stateful references to state.
For consistency we are using 'state' these days, not 'stateful'. While
I'm mucking around in this code it seems like a good time to switch.
2013-08-20 22:36:53 -04:00
Michael Marineau
ebbd281f0d cleanup(gen_tmpfiles): Move to build_library 2013-08-20 22:19:00 -04:00
Michael Marineau
ad908d0820 fix(gen_tmpfiles): Don't include /var/tmp, systemd defines this one. 2013-08-20 22:16:37 -04:00
Michael Marineau
efac054f54 fix(build_library): Remove usb and factory_layout partition layouts.
These are just cluttering things and adding an element of "how does this
work?" because base_image_util was defaulting to the "usb" layout in
some places and "base" in others.
2013-08-20 21:47:53 -04:00
Michael Marineau
34c324cc3a fix(build_library): Remove GPT writer scripts, call cgpt directly.
This change removes /usr/sbin/write_gpt.sh from images which we have no
use for. This allows us to drop the indirection of writing partition
tables by first writing out a script to call. Now cgpt.py can call cgpt
directly to initialize the partition layout. This opens the way for
further improvements to how disk images are created.
2013-08-20 21:30:22 -04:00
Michael Marineau
1ad0ea2eab fix(cgpt.py): Remove broken 'expand' feature.
This currently does nothing because our state partition is not partition
number 1. Even if it did we don't really needed it since we rely on
expanding on boot instead.
2013-08-20 21:09:06 -04:00
Michael Marineau
4976302373 remove(verify_rootfs_chksum.sh): Unused, we don't use verity. 2013-08-19 18:09:11 -04:00
Michael Marineau
325755e923 cleanup(build_image): Remove some unused flags.
Remove --verity_*: Unused, we don't support verity
Remove --usb_disk: Unused, we use PARTUUID now.
Remove --enable_serial: Unused, and serial is enabled for syslinux
2013-08-19 18:09:11 -04:00
Michael Marineau
d8e670a2b3 fix(build_image): Don't over-size root partitions in base images.
Right now the initial (pre image_to_vm) images oversize the root
partitions, creating the expected 1GB filesystem in a 2GB partition.
image_to_vm later shrinks the partition back down to match. Just start
out with 1GB partitions to begin with instead.
2013-08-19 18:09:11 -04:00
Michael Marineau
89fa680892 Merge pull request #90 from marineam/ami
feat(test_ami): Add support for finding AMI by version.
2013-08-19 15:03:09 -07:00
Michael Marineau
7f6cdde553 feat(test_ami): Add support for finding AMI by version.
This makes chaining the build and test ami scripts together easier.
2013-08-19 17:35:10 -04:00
polvi
5253064d32 Merge pull request #88 from polvi/ami-test
test(ami-test): basic script for testing ami and bootstrapping
2013-08-18 21:24:12 -07:00
Michael Marineau
10f6a550fc Merge pull request #89 from marineam/qemu
feat(image_to_vm): Add new and improved qemu wrapper script.
2013-08-18 17:27:04 -07:00
Michael Marineau
0f84e3b05f feat(image_to_vm): Add new and improved qemu wrapper script.
This one is more automagical and sets up ssh keys from ssh-agent and the
user's home directory by default. Also adds an option for setting the
ssh port so it can be something other than 2222. Script should be
sufficiently portable, tested in bash, dash, and ash.
2013-08-18 19:43:07 -04:00
Alex Polvi
a191ff9973 Used uuidgen
Refacted timeout section to be a loop
Added output for progress
Fixed indentation
2013-08-18 09:15:15 -07:00
Alex Polvi
f986ba2d03 test(ami-test): basic script for testing ami and bootstrapping 2013-08-17 00:51:50 -07:00