Skip to content

Commit

Permalink
Merge pull request #71 from jflf-CV/fixes
Browse files Browse the repository at this point in the history
RPM GPG key improvements
  • Loading branch information
hicham-a committed Sep 5, 2016
2 parents 679538e + 2eadfea commit bb7396d
Show file tree
Hide file tree
Showing 12 changed files with 10 additions and 50 deletions.
11 changes: 0 additions & 11 deletions configuration/controller.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -160,17 +160,6 @@ YUM_PERSISTENT_CACHE=1
#REPOS_DISABLE_REMOTE=0


#-----------------------------------------------------------
# additional-repos
#-----------------------------------------------------------

# List of repository GPG key files.
# There is no coherent naming convention for those, so list them all here.
# They should be available in the "additional-repos" subdirectory.

ADDREPOS_KEYS="RPM-GPG-KEY-elrepo.org RPM-GPG-KEY-ZABBIX"


#-----------------------------------------------------------
# firewalld
#-----------------------------------------------------------
Expand Down
19 changes: 8 additions & 11 deletions configuration/controller/additional-repos.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#!/bin/bash

# Add other repositories by default
# Add other RPM repositories

# It may seem weird to install those repo files from a local directory instead
# of pulling them off of the internet, but again, there is no guarantee that the
Expand All @@ -9,31 +8,28 @@
ret=0

# Key files
# No reliable naming convention, so they have to be provided

if [[ "$ADDREPOS_KEYS" ]] ; then
if ls "${POST_FILEDIR}/keys/"* >/dev/null 2>&1 ; then
echo_info 'Installing repository GPG keys'
for i in $ADDREPOS_KEYS ; do
cp "${POST_FILEDIR}/$i" /etc/pki/rpm-gpg/
rpm --import "${POST_FILEDIR}/$i"
(( ret += $? ))
done
cp "${POST_FILEDIR}/keys/"* /etc/pki/rpm-gpg/
rpm --import "${POST_FILEDIR}/keys/"*
(( ret += $? ))
fi


# Repo packages
echo_info 'Installing RPM files'

if ls "${POST_FILEDIR}/"*.rpm >/dev/null 2>&1 ; then
echo_info 'Installing RPM files'
install_rpm_files "${POST_FILEDIR}/"*.rpm
(( ret += $? ))
fi


# Individual repo files
echo_info 'Installing repo files'

if ls "${POST_FILEDIR}/"*.repo >/dev/null 2>&1 ; then
echo_info 'Installing repo files'
cp "${POST_FILEDIR}/"*.repo /etc/yum.repos.d
(( ret += $? ))
fi
Expand All @@ -45,6 +41,7 @@ flag_is_set REPOS_DISABLE_REMOTE && disable_remote_repos


# Finally, make sure that the cache is updated

if flag_is_unset POST_CHROOT ; then
echo_info 'Updating yum cache'

Expand Down
11 changes: 0 additions & 11 deletions configuration/images-setup-compute.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -99,17 +99,6 @@ STDCFG_SSHROOT=1
#REPOS_DISABLE_REMOTE=0


#-----------------------------------------------------------
# additional-repos
#-----------------------------------------------------------

# List of repository GPG key files.
# There is no coherent naming convention for those, so list them all here.
# They should be available in the "additional-repos" subdirectory.

ADDREPOS_KEYS="RPM-GPG-KEY-elrepo.org RPM-GPG-KEY-ZABBIX"


#-----------------------------------------------------------
# chrony
#-----------------------------------------------------------
Expand Down
10 changes: 0 additions & 10 deletions configuration/images-setup-openstack-compute.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,6 @@ POSTLIST=( \
)


#-----------------------------------------------------------
# additional-repos
#-----------------------------------------------------------

# List of repository GPG key files.
# There is no coherent naming convention for those, so list them all here.
# They should be available in the "additional-repos" subdirectory.

ADDREPOS_KEYS="RPM-GPG-KEY-elrepo.org RPM-GPG-KEY-ZABBIX RPM-GPG-KEY-CentOS-SIG-Cloud"


#-----------------------------------------------------------
# openstack services
Expand Down
5 changes: 0 additions & 5 deletions configuration/openstack.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,6 @@ POSTLIST=( \
CTRL1_HOSTNAME=os-controller
CTRL1_IP=10.30.254.254

#-----------------------------------------------------------
# additional-repos
#-----------------------------------------------------------

ADDREPOS_KEYS="${ADDREPOS_KEYS} RPM-GPG-KEY-CentOS-SIG-Cloud"

#-----------------------------------------------------------
# rabbitmq
Expand Down

This file was deleted.

This file was deleted.

0 comments on commit bb7396d

Please sign in to comment.