Commit Graph

2650 Commits

Author SHA1 Message Date
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
Michael Marineau
5c335a5c39 Merge pull request #87 from marineam/official
fix(common.sh): Do not add dev build id when outside a repo checkout.
2013-08-16 19:05:54 -07:00
Michael Marineau
ba9dd61aeb fix(common.sh): Do not add dev build id when outside a repo checkout.
When running from a au zip or other strange situation assume the version
in version.txt should be used as-is. This avoid the need to set
COREOS_OFFICIAL=1 in these situations which can be lead to surprises.
2013-08-16 21:47:31 -04:00
Michael Marineau
7b8036c947 Merge pull request #86 from marineam/bootargs
Bootargs
2013-08-16 15:47:55 -07:00
Michael Marineau
81afa4f300 fix(boot): Enable serial console when booting via syslinux.
Useful for qemu -nographic or any any other situation where serial is
easier to get at than VGA. It may be possible that in some setups ttyS0
isn't appropriate but we can figure out a way to customize kernel
options if/when that ever comes up.
2013-08-16 15:18:31 -04:00
Michael Marineau
c21b8ee03d cleanup(boot): remove lingering dm-verity bits, cleanup kernel args.
Remove unused dev/dm-0 vs dm-1 logic from verity and the associated
rootwait option it required (meaningless with our initrd). Move old
cros_legacy to common instead of using it in every command line option.
We should remove it entirely soon since it isn't useful for us. Remove
unneeded intel graphics modeset option.
2013-08-16 15:00:29 -04:00
Michael Marineau
2edd22024e fix(build_image): Remove noinitrd from default boot_args 2013-08-14 13:15:20 -04:00
Brandon Philips
b75a356352 Merge pull request #85 from marineam/quickfix
fix(image_to_vm): Fix backslash in qemu README.
2013-08-11 21:34:55 -07:00
Michael Marineau
b0d2775e0a fix(image_to_vm): Fix backslash in qemu README.
Go me fixing this issue in the script while adding it in the README.
2013-08-11 23:41:05 -04:00
Michael Marineau
83816ae4aa Merge pull request #84 from marineam/virtfs
Virtfs bits
2013-08-11 20:19:04 -07:00
Michael Marineau
bef5728f6e fix(image_to_vm): Cleanup qemu script, document -virtfs 2013-08-11 22:17:20 -04:00
Michael Marineau
ba4c770c37 fix(common): Exclude default systemd filesystem targets.
We don't need the default root filesystem fsck and remount targets
provided by systemd since root is read only. The only default one what
was included in this way was tmp.mount but that is now covered by
a dependency in the coreos-init package.
2013-08-11 14:50:05 -04:00
Michael Marineau
ebc1afe67f Merge pull request #83 from marineam/curl-ami-fix
fix(build_ebs_on_ec2.sh): Add --fail to all curl commands.
2013-08-07 13:14:09 -07:00
Michael Marineau
3ef4757fd4 fix(build_ebs_on_ec2.sh): Add --fail to all curl commands.
This is particularly important for the image availability pre-check
because without it we don't detect that the image is in-fact unavailable
when it doesn't exist and the 404 results in a error from bzip2.
2013-08-07 15:44:52 -04:00
Michael Marineau
f48858b6eb Merge pull request #82 from marineam/fix-cmp
Fix cmp
2013-08-07 10:39:34 -07:00
Michael Marineau
a0f383e3fe fix(common): sort -R is random, -r is reverse. Kids, use long options...
Randomly failing builds for fun and profit!
2013-08-07 12:38:58 -04:00
Michael Marineau
5ac0bcdd27 fix(update_chroot): Generate make.conf.host_setup before update scripts.
This doesn't currently have any real impact but seems like a better
ordering since update scripts may need to emerge things.

Add some friendly version info logging.
2013-08-07 12:29:10 -04:00
Michael Marineau
f871c34186 Merge branch 'master' of ssh://github.com/coreos/scripts 2013-08-06 18:45:16 -04:00
Michael Marineau
28b2ffabec fix(update_chroot): Remove an old debug echo 2013-08-06 17:38:28 -04:00
Michael Marineau
5fa0f93134 fix(make_chroot): Remove the old "force-to-latest" chroot version step.
This script is gone and dead.
2013-08-06 17:30:54 -04:00
Michael Marineau
c4219e592e fix(make_chroot): Write sudoers.d/90_cros directly.
Previously this called a file in the now deleted chroot_version_hooks.d
which surprised me to say the least but it really shouldn't have...
2013-08-06 17:19:13 -04:00
polvi
3a1d4dbe1b Merge pull request #80 from polvi/vagrant-vmware
feat(vagrant): vmware fusion support
2013-08-06 14:01:00 -07:00
Michael Marineau
64c75ff315 Merge pull request #79 from marineam/lsb4sdk
Add lsb-release to SDK tarballs
2013-08-06 13:24:52 -07:00
Alex Polvi
324f4d86f2 call it --format=vagrant_vmware_fusion 2013-08-06 11:14:03 -07:00
Alex Polvi
55062ec902 feat(vagrant): vmware fusion support 2013-08-06 10:58:18 -07:00
Michael Marineau
74c4f21b68 fix(update_chroot): Replace old chroot version scheme.
The old chroot version system we inherited from Chromium OS always
assumes that a newly unpacked tarball is the latest and greatest but
since we version the SDK in the same way as target builds we can use
that version for these sorts of upgrade scripts and not make assumptions
about how late and great the starting tarball was.

The first upgrade script simply aborts to force the user to recreate
their chroot when moving from python 2.6 to 2.7.
2013-08-06 13:54:18 -04:00
Michael Marineau
19caadc8c9 feat(common): Add simple version comparison function.
Relies on sort for version comparison which should generally be good
enough. Not a proper semver tool but good enough for dirty scripts. :)
2013-08-06 13:50:17 -04:00
Michael Marineau
9794ab32b1 feat(bootstrap_sdk): Add release data to SDK tarballs. 2013-08-05 23:18:41 -04:00
Michael Marineau
3600615dc8 fix(bootstrap_sdk): skip final release goo if stage4 wasn't built 2013-08-05 22:44:27 -04:00
Michael Marineau
a21a545f2e fix(set_lsb_release): Make sure $ROOT/etc exists.
Useful for generating a root filesystem overlay that catalyst can apply.
2013-08-05 22:38:34 -04:00
Michael Marineau
ff6af5ea8f feat(set_lsb_release): Add special "sdk" track without an update server.
I want to start including version info in SDK builds as an alternative
scheme to the existing "chroot_version_hooks" system which always
assumes freshly unpacked SDKs are the latest regardless of what version
they actually were.
2013-08-05 22:35:34 -04:00
Michael Marineau
e90ae75b18 Merge pull request #78 from marineam/sdkver
feat(master_release): Add option to automatically bump SDK_VERSION.
2013-08-05 17:00:30 -07:00
Michael Marineau
8a34fc8af8 feat(master_release): Add option to automatically bump SDK_VERSION.
Usually the only time these versions really need to mis-match are when
branching a brand new version.
2013-08-05 16:47:28 -04:00
Michael Marineau
25576f3d7e Merge pull request #77 from marineam/qcow2
Qemu, Qcow2, and Openstack
2013-08-02 12:45:20 -07:00