I'm trying to use Oz to create a CentOS 6.4 virtual machine image and install some packages from EPEL. When it tries to install the epel-release package, I get the error:
Public key for epel-release-6-8.noarch.rpm is not installed
I can pass a custom kickstart file to Oz, so my thinking is to import this key in the post-installation script. What should I put in the %post
section so the appropriate key gets imported?
For reference, here's what my Oz template looks like this:
<template>
<name>centos-6.4</name>
<os>
<name>CentOS-6</name>
<version>4</version>
<arch>x86_64</arch>
<install type='iso'>
<iso>file:///data/isos/CentOS-6.4-x86_64-bin-DVD1.iso</iso>
</install>
</os>
<description>CentOS 6.4 x86_64</description>
<repositories>
<repository name='epel-6'>
<url>http://download.fedoraproject.org/pub/epel/6/$basearch</url>
<signed>yes</signed>
</repository>
</repositories>
<packages>
<package name="epel-release" />
<package name="cloud-utils" />
<package name="cloud-init" />
</packages>
</commands>
</template>
(I could just turn off the check for signed packages, but I'd like to figure out how to do this without turning off that check).
Edit: Here's what my custom kickstart currently looks like:
install
text
key --skip
keyboard us
lang en_US.UTF-8
skipx
network --device eth0 --bootproto dhcp
rootpw %ROOTPW%
firewall --disabled
authconfig --enableshadow --enablemd5
selinux --disabled
timezone --utc America/New_York
bootloader --location=mbr --append="console=tty0 console=ttyS0,115200"
zerombr yes
clearpart --all
part / --fstype ext4 --size=1024 --grow
reboot
%packages
@base
%post
# What do I put here???