GCE Images with Imagefactory/oz

Renich Bon Ciric renich at woralelandia.com
Fri Jun 27 23:18:06 UTC 2014


On Wed, Jun 25, 2014 at 11:12 AM, Richard W.M. Jones <rjones at redhat.com> wrote:
> So I've only skimmed the Google Cloud Engine docs, but this would be
> how you could do this with virt-builder ...
>
>   $ virt-builder fedora-20 --output disk.raw --size 10G \
>       --install bash-completion,denyhosts,irqbalance,ntp,patch,rsyslog,yum-cron-daily \
>       --hostname metadata.google.internal \
>       --write '/etc/hosts:
> 127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
> 169.254.169.254 metadata.google.internal metadata
> ' \
>
> # use --write or --upload for the other files
>
>       --delete /etc/sysconfig/networking \
>       --edit '/etc/ntp.conf:
>                    /^server [1-3]\.fedora.*$/d' \
>       --run-command 'systemctl disable firewalld.service iptables.service' \
>
> # (I got bored, there are more commands ...)
>
>   $ tar zcf fedora-20.tar.gz disk.raw
>
> No root needed!
>
> Rich.


Oh, please, check out my version of things here:
https://github.com/renich/gce-images-fedora/tree/master/virt-builder

I'd love a review by the creator! ;)

I tried to keep the command not so bloated. I used a --firstboot
command to put everything I could in the script. At least things that
don't require scripts as parameters.

The "build" is the command and "setup" is the script to follow; very
much ike a post-install section on a kickstart.

-- 
It's hard to be free... but I love to struggle. Love isn't asked for;
it's just given. Respect isn't asked for; it's earned!
Renich Bon Ciric

http://www.woralelandia.com/
http://www.introbella.com/


More information about the cloud mailing list