Skip to content

Instantly share code, notes, and snippets.

@aweiteka
Last active December 21, 2015 03:48
Show Gist options
  • Save aweiteka/6244550 to your computer and use it in GitHub Desktop.
Save aweiteka/6244550 to your computer and use it in GitHub Desktop.
RHEVM additional setup for CFME
# Additional RHEVM config need for cap&util data collection
# per https://access.redhat.com/site/articles/411683
yum install -y rhevm-reports
echo "yes" | rhevm-dwh-setup
# FIXME: multi-prompt approach not working... need expect? :(
rhevm-reports-setup << EOT
yes "\n"
redhat "\n"
redhat "\n"
EOT
# iptables
iptables -A INPUT -p tcp -m state --state NEW -m tcp --dport 5432 -j ACCEPT
service iptables save
# pg conf unnecessary in current config:
#echo "host all all 0.0.0.0/0 md5" >> /var/lib/pgsql/data/pg_hba.conf
# psql create role
# create cmd file
cat > create_role <<EOT
CREATE ROLE cfme LOGIN UNENCRYPTED PASSWORD 'my_passwd' SUPERUSER VALID UNTIL 'infinity';
\q
EOT
# FIXME: prompted for passwd
psql --username=postgres --file=create_role
service postgresql restart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment