Ansible getversion of the remote server and create a csv 3/3.
HTML-код
- Опубликовано: 27 авг 2024
- Install AWX, follow below youtube,
• How to install Ansible...
Instruction cli on centos7,
su - root
cd ~
getenforce
vi /etc/selinux/config
sudo reboot now
getenforce
yum install -y epel-release
yum repolist
chattr -i /etc/resolv.conf
vi /etc/resolv.conf
systemctl restart network
systemctl status firewalld #just disable firewalld
ping github.com
yum install -y git gcc gcc-c++ ansible nodejs gettext device-mapper-persistent-data lvm2 python3-pip vim wget
wget https-download.docker.com/linux/centos/docker-ce.repo --directory-prefix /etc/yum.repos.d/ # url remove?!? figure out urself
yum install -y docker-ce #make sure this install not "docker"
systemctl start docker
systemctl enable docker
ssh-keygen
pip3 install -U pip setuptools
pip3 install docker-compose
git clone -b 17.1.0 https-github.com/ansible/awx.git # version 17 # url remove?!? figure out urself
$openssl rand -base64 30
sVXN426UfaQ/LGDaxsRXfExwWMq1ouXDsp8eAFx1
sed 's/postgres_data_dir=\"~\/.awx\/pgdocker\"/postgres_data_dir=\"\/var\/lib\/awx\/pgdocker"/g' -i ~/awx/installer/inventory
sed 's/docker_compose_dir=\"~\/.awx\/awxcompose\"/docker_compose_dir=\"\/var\/lib\/awx\/pgdocker\"/g' -i ~/awx/installer/inventory
sed 's/pg_database=awx/pg_database=postgres/g' -i ~/awx/installer/inventory
sed 's/admin_user=admin/admin_user=ric/g' -i ~/awx/installer/inventory
sed 's/# admin_password=password/admin_password=ric/g' -i ~/awx/installer/inventory
sed 's/secret_key=awxsecret/secret_key=sVXN426UfaQ\/LGDaxsRXfExwWMq1ouXDsp8eAFx1/g' -i ~/awx/installer/inventory
sed 's/#awx_alternate_dns_servers=\"10.1.2.3,10.2.3.4\"/awx_alternate_dns_servers=\"8.8.8.8,4.4.4.4,192.168.133.2\"/g' -i ~/awx/installer/inventory
sed 's/#project_data_dir=\/var\/lib\/awx\/projects/project_data_dir=\/var\/lib\/awx\/projects/g' -i ~/awx/installer/inventory
verify,
cat ~/awx/installer/inventory | grep postgres_data_dir
cat ~/awx/installer/inventory | grep docker_compose_dir
cat ~/awx/installer/inventory | grep pg_database
cat ~/awx/installer/inventory | grep admin_user
cat ~/awx/installer/inventory | grep admin_password
cat ~/awx/installer/inventory | grep secret_key
cat ~/awx/installer/inventory | grep awx_alternate_dns_servers
cat ~/awx/installer/inventory | grep project_data_dir
ansible-playbook -i ~/awx/installer/inventory ~/awx/installer/install.yml
PUT on your browser localhost and LOGIN
Galaxies,
github.com/rv-...
github.com/rv-...
Yaml caller,
github.com/rv-...
The password shown there accidentally was already replaced...... again no take 2 and it got 2 factor oath anyways. Наука