
merms_panel=# select name, product_id,status from products;
name                 | product_id | status
----------------------+------------+--------
Professional Website | A000002    |      1
Professional Blog    | A000004    |      1
Practice EMR         | A000005    |      1
Personal Website     | A000001    |      5
Personal Blog        | A000003    |      5
(5 rows)


https://dev.to/nithinalias/docker-compose-install-wordpress-using-ansible-2lnh


[web_servers]
172.16.250.132
172.16.250.248

[db_servers]
172.16.250.133

[file_servers]
172.16.250.134


https://www.learnlinux.tv/getting-started-with-ansible-09-targeting-specific-nodes/

#version: '3'
services:
website-WHAT_CONTAINER_NAME:
container_name: WHAT_CONTAINER_NAME
#image: yeasy/simple-web
image: registry.chiefsoft.com/pweb/pweb-01-merms-pweb0003:latest
pull_policy: always
ports:
- 'ALLOCATED_PORT:80'
restart: always
volumes:
- ./writable:/var/www/html/writable:Z
- ./apache_log:/var/log/apache2:Z
#    environment:
#      - APACHE_RUN_USER=1000
#      - APACHE_RUN_GROUP=1000
    networks:
      - sitenet

#networks:
#  sitenet:

networks:
sitenet:
#    driver: bridge
#    ipam:
#      driver: default
#      config:
#        - subnet: 171.11.0.0/16
##          ip_range: 172.28.5.0/24
##          gateway: 172.28.5.254


ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml



    1  ifconfig
    2  sudo apt install net-tools
    3  sudo nano /etc/netplan/00-installer-config.yaml 
    4  sudo reboot now
    5  sudo chiefsoft@172.16.4.91
    6  ssh chiefsoft@172.16.4.91
    7  ssh chiefsoft@172.16.4.92
    8  ssh chiefsoft@172.16.4.95
    9  ls -la .ssh
10  ls
11  ssh-keygen -t ed25519 -C "ansible 90 default"
12  ls -la .ssh
13  ssh-copy-id -i ~/.ssh/id_ed25519.pub 172.16.4.91
14  ssh-copy-id -i ~/.ssh/id_ed25519.pub 172.16.4.92
15  ssh 172.16.4.91
16  ssh-keygen -t ed25519 -C "ansible 90 worker"
17  ssh-copy-id -i ~/.ssh/ansible_worker.pub 172.16.4.91
18  ssh-copy-id -i ~/.ssh/ansible_worker.pub 172.16.4.92
19  ssh 172.16.4.91
20  ssh -i ~/.ssh/ansible_worker 172.16.4.91
21  ssh -i ~/.ssh/ansible_worker 172.16.4.92
22  which git
23  sudo apt update
24  sudo nano /etc/hosta
25  sudo nano /etc/hoss
26  sudo nano /etc/hosts
27  less .ssh/id_ed25519.pub
28  ls
29  git clone ssh://git@gitlab.chiefsoft.net/ChiefSoftLab/Ansible.git
30  git clone ssh://chiefsoft@gitlab.chiefsoft.net/ChiefSoftLab/Ansible.git
31  git clone https://gitlab.chiefsoft.net/ChiefSoftLab/Ansible.git
32  ls
33  sudo apt install ansible
34  ls
35  c Ansible/
36  cd Ansible/
37  ls
38  nano inventory
39  less inventory
40  git add inventory
41  git commit -m fix inventory
42  git commit -m fix  
43  git commit -m fix inventory
44  git push
45  ansible all --key-file ~/.ssh/ansible_worker -i inventory -m  ping
46  nano ansible.cfg
47  ls
48  nano README.md
49  ansible all -m  ping
50  nano ansible.cfg
51  ansible all -m  ping
52  ansible all --list-hosts
53  ansible all -m gahther_facst
54  ansible all -m gahther_facts
55  ansible all -m gather_facts
56  ansible all -m gather_facts --limit 172.16.4.91
57  git add ansible.cfg
58  git commit -m fix
59  git push
60  ansible all -m apt -a update_cache=true
61  ansible all -m apt -a update_cache=true --become --ask-become-pass
62  ansible all -m apt -a name=vim-nox --become --ask-become-pass
63  ansible all -m apt -a name=snapd --become --ask-become-pass
64  ansible all -m apt -a "name=snapd state=latest" --become --ask-become-pass
65  ansible all -m apt -a "upgrade=dist" --become --ask-become-pass
66  nano install_apache.yml
67  ansible-playbook --ask-become-pass install_apache.yml
68  nano install_apache.yml
69  ansible-playbook --ask-become-pass install_apache.yml
70  nano install_apache.yml
71  ansible-playbook --ask-become-pass install_apache.yml
72  nano docker.yml
73  ansible-playbook --ask-become-pass docker.yml
74  git status
75  git add docker.yml
76  git add install_apache.yml
77  git commit -m fix
78  git push
79  ls
80  git clone https://gitlab.chiefsoft.net/MERMS/MermsProvision.git
81  ls
82  docker ps
83  sudo apt  install docker.io
84  cd MermsProvision/
85  ls
86  ls ANSIBLE/
87  docker-compose
88  sudo apt  install docker-compose
89  sudo docker-compose up -d --build
90  ls
91  cd ..
92  sudo chmod -R 0777 MermsProvision/
93  cd MermsProvision/
94  sudo docker-compose up -d --build
95  sudo docker-compose up -d
96  sudo docker-compose up -d --build
97  less docker-compose.yml
98  less .env
99  sudo reboot now
100  cd MermsProvision/
101  ls
102  sudo docker-compose up -d --build
103  sudo docker ps
104  sudo mkdir writable
105  sudo chmod -R 0777 writable/
106  less writable/
107  sudo docker-compose up -d --build
108  ls writable/
109  ls
110  ls system/
111  ls writable/
112  ls apache_log/
113  ls apache_log/error.log
114  less apache_log/error.log
115  less apache_log/other_vhosts_access.log
116  git pull
117  sudo chmod -R 0777 ANSIBLE/
118  ls ANSIBLE/
119  less ANSIBLE/23233_A000001_mermsemr_com.yml
120  git pull
121  git stash
122  git pull
123  ls
124  cd MermsProvision/
125  ls
126  cd ANSIBLE/
127  ls
128  ls -alt
129  cd ..
130  git pull
131  sudo nano /etc/hosts
132  git pull
133  ls
134  cd ANSIBLE/
135  ls
136  cd ..
137  ls tests/
138  ls ANSIBLE/
139  ls ANSIBLE/templates/
140  git pull
141  ls ANSIBLE/
142  tail -f writable/logs/log-2025-01-20.log
143  git pull
144  tail -f writable/logs/log-2025-01-20.log
145  ls ANSIBLE/parts/
146  sudo chmod -R 0777 ANSIBLE/parts/
147  tail -f writable/logs/log-2025-01-20.log
148  less ANSIBLE/63404_A000003_mermsemr_com.yml
149  git pull
150  tail -f writable/logs/log-2025-01-20.log
151  sudo docker ps
152  docker exec -it mermsprovision_merms-provision_1 bash
153  sudo docker exec -it mermsprovision_merms-provision_1 bash
154  docker compose up -d --build
155  sudo docker-compose up -d --build
156  tail -f writable/logs/log-2025-01-20.log
157  dir pull
158  git pull
159  tail -f writable/logs/log-2025-01-20.log
160  cd ANSIBLE/
161  ls
162  ls -alt
163  history
164  ls -alt
165  ansible-playbook --ask-become-pass 57257_A000003_mermsemr_com.yml
166  ansible-playbook --ask-become-pass -i inventory 57257_A000003_mermsemr_com.yml
167  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
168  sudo ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
169  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
170  sudo docker exec -it mermsprovision_merms-provision_1 bash
171  sudo chmod -R 0777 parts/
172  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
173  pwd
174  cd ..
175  git pull
176  cd ANSIBLE/
177  ls
178  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
179  cd parts/
180  ls
181  pwd
182  cd ..
183  ls
184  git pull
185  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
186  cd ANSIBLE/
187  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
188  cd ..
189  git pull
190  cd ANSIBLE/
191  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
192  cd ..
193  git pull
194  cd ANSIBLE/
195  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
196  cd ..
197  git pull
198  cd ANSIBLE/
199  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
200  cd ..
201  git pull
202  cd ANSIBLE/
203  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
204  cd ..
205  git pull
206  cd ANSIBLE/
207  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 57257_A000003_mermsemr_com.yml
208  ls
209  cd MermsProvision/
210  ls
211  git pull
212  tail -f writable/logs/log-2025-01-20.log
213  sudo docker ps
214  tail -f writable/logs/log-2025-01-
215  git pull
216  cd MermsProvision/
217  git pull
218  tail -f writable/logs/log-2025-01-20.log
219  git pull
220  tail -f writable/logs/log-2025-01-20.log
221  cd MermsProvision/
222  git pull
223  tail -f writable/logs/log-2025-01-20.log
224  tail -f writable/logs/log-2025-01-22.log
225  git pull
226  tail -f writable/logs/log-2025-01-22.log
227  cd ANSIBLE/
228  ls
229  ls -alt
230  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 49819_devprov_mermsemr_com.yml
231  ls -alt
232  less 37338_devprov_mermsemr_com.yml
233  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 37338_devprov_mermsemr_com.yml
234  ls -alt
235  cd ..
236  ls
237  git pull
238  tail -f writable/logs/log-2025-01-22.log
239  tail -f writable/logs/log-2025-01-23.log
240  git pull
241  tail -f writable/logs/log-2025-01-22.log
242  tail -f writable/logs/log-2025-01-23.log
243  git pull
244  tail -f writable/logs/log-2025-01-23.log
245  sudo docker ps
246  cd MermsProvision/ANSIBLE/
247  ls -alt
248  less 37338_devprov_mermsemr_com.yml
249  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 37338_devprov_mermsemr_com.yml
250  ls
251  cd MermsProvision/ANSIBLE/
252  ls -alt
253  ansible-playbook --ask-become-pass --key-file ~/.ssh/ansible_worker -i inventory 23607_devprov_mermsemr_com.yml
254  echo "your_secret_password" > vault_pass.txt
255  ls
256  less vault_pass.txt
257  ansible-vault create secrets.yml --vault-password-file vault_pass.txt
258  less secrets.yml
259  ansible-vault create secrets.yml --vault-password-file vault_pass.txt
260  ps -auxf
261  ls
262  ansible-playbook --vault-password-file  secrets.yml --key-file ~/.ssh/ansible_worker -i inventory 23607_devprov_mermsemr_com.yml
263  nano secrets.pass
264  ansible-playbook --vault-password-file  secrets.yml  --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 23607_devprov_mermsemr_com.yml
265  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 23607_devprov_mermsemr_com.yml
266  ls -alt
267  cd ..
268  git pull
269  tail -f writable/logs/log-2025-01-23.log
270  ps -auxf
271  cd ANSIBLE/
272  ls -alt
273  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 89354_devprov_mermsemr_com.yml
274  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 23233_devprov_mermsemr_com.yml
275  less 82790_devprov_mermsemr_com.yml
276  less inventory
277  less 49819_devprov_mermsemr_com.yml
278  less 33271_devprov_mermsemr_com.yml
279  ls -alt
280  less 49819_devprov_mermsemr_com.yml
281  less 73344_devprov_mermsemr_com.yml
282  less 89354_devprov_mermsemr_com.yml
283  less 23233_devprov_mermsemr_com.yml
284  ls -alt
285  cd ..
286  git pull
287  tail -f writable/logs/log-2025-01-23.log
288  git pull
289  cd ANSIBLE/
290  clear
291  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 11833_devprov_mermsemr_com.yml
292  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 94099_devprov_mermsemr_com.yml
293  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 33271_devprov_mermsemr_com.yml
294  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 49819_devprov_mermsemr_com.yml
295  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 82790_devprov_mermsemr_com.yml
296  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 23233_devprov_mermsemr_com.yml
297  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 89354_devprov_mermsemr_com.yml
298  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 73344_devprov_mermsemr_com.yml
299  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 37338_devprov_mermsemr_com.yml
300  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 43333_devprov_mermsemr_com.yml
301  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 85959_devprov_mermsemr_com.yml
302  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 23607_devprov_mermsemr_com.yml
303  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 57257_devprov_mermsemr_com.yml
304  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 63404_devprov_mermsemr_com.yml
305  cd ..
306  git pull
307  sudo nano app/Controllers/Provision.php
308  tail -f writable/logs/log-2025-01-23.log
309  sudo nano app/Controllers/Provision.php
310  cd ANSIBLE/
311  la
312  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 11833_devprov_mermsemr_com.yml
313  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 94099_devprov_mermsemr_com.yml
314  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 33271_devprov_mermsemr_com.yml
315  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 49819_devprov_mermsemr_com.yml
316  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 82790_devprov_mermsemr_com.yml
317  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 23233_devprov_mermsemr_com.yml
318  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 89354_devprov_mermsemr_com.yml
319  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 73344_devprov_mermsemr_com.yml
320  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 37338_devprov_mermsemr_com.yml
321  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 43333_devprov_mermsemr_com.yml
322  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 85959_devprov_mermsemr_com.yml
323  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 23607_devprov_mermsemr_com.yml
324  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 57257_devprov_mermsemr_com.yml
325  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 63404_devprov_mermsemr_com.yml
326  cd ..
327  git pull
328  ls -l
329  cd MermsProvision/
330  ls -l
331  cd AN
332  cd ANSIBLE/
333  ls -l
334  vim ~/.ssh/authorized_keys
335  exit
336  cd ~/MermsProvision/ANSIBLE
337  ls -l
338  cd ..
339  ls -l
340  docker ps
341  sudo usermod -aG docker $USER
342  docker ps
343  exit
344  docker ps
345  ls -l
346  docker pull quay.io/ansible/awx
347  docker images
348  docker rmi 5a8467008731 4f1609f6a243
349  ansible --version
350  docker --version
351  docker-compose --version
352  wget https://github.com/ansible/awx/archive/17.1.0.zip
353  ls -l
354  unzip 17.1.0.zip
355  sudo apt install unzip
356  unzip 17.1.0.zip
357  cd awx-17.1.0/installer
358  pwgen -N 1 -s 40
359  sudo apt install pwgen
360  pwgen -N 1 -s 40
361  vim inventory
362  ls -l
363  vim install.yml
364  ls -l roles
365  ls -l roles/local_docker/
366  mc
367  sudo apt install mc
368  mc
369  git clone https://github.com/ansible/awx.git
370  rm -rf awx
371  git clone -b 24.6.1 https://github.com/ansible/awx.git
372  vim tools/docker-compose/inventory
373  cd awx
374  vim tools/docker-compose/inventory
375  make docker-compose-build
376  sudo apt install build-essential
377  make docker-compose-build
378  sudo apt install docker-buildx-plugin
379  docker buildx install
380  apt-cache search buildx
381  sudo apt install docker-buildx
382  docker buildx install
383  docker info | head -n8
384  make docker-compose-build
385  dnf
386  sudo apt install dnf
387  make docker-compose-build
388  git checkout 24.5.0
389  make docker-compose-build
390  cd ..
391  rm -rf awx
392  git clone -b 21.5.0 https://github.com/ansible/awx.git
393  cd awx
394  git branch
395  make docker-compose
396  cd ..
397  mkdir semaphore
398  cd semaphore
399  vim docker-compose.yml
400  head -c32 /dev/urandom | base64
401  vim docker-compose.yml
402  docker-compose up -d
403  docker ps
404  ip addr
405  sudo iptables -L -n
406  ufw status
407  sudo ufw status
408  uname -a
409  lsb_release -a
410  sudo iptables -L -n
411  curl http://localhost:3000/
412  docker ps
413  docker logs --tail 100 -f semaphore_semaphore_1
414  docker-compose down
415  docker-compose up
416  vim docker-compose.yml
417  docker-compose up
418  bg
419  ls
420  cd MermsProvision/
421  ls
422  cd ANSIBLE/
423  ls
424  ls -alt
425  less 63404_devprov_mermsemr_com.yml
426  cd ..
427  git pull
428  cd ANSIBLE/
429  ls
430  ls -alt
431  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 49819_devprov_mermsemr_com.yml
432  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 33271_devprov_mermsemr_com.yml
433  ls -alt
434  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 23607_devprov_mermsemr_com.yml
435  sudo docker ps
436  cd MermsProvision/
437  cd ANSIBLE/
438  ls
439  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 11833_devprov_mermsemr_com.yml
440  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 94099_devprov_mermsemr_com.yml
441  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 33271_devprov_mermsemr_com.yml
442  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 49819_devprov_mermsemr_com.yml
443  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 82790_devprov_mermsemr_com.yml
444  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 23233_devprov_mermsemr_com.yml
445  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 89354_devprov_mermsemr_com.yml
446  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 73344_devprov_mermsemr_com.yml
447  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 37338_devprov_mermsemr_com.yml
448  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 43333_devprov_mermsemr_com.yml
449  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 85959_devprov_mermsemr_com.yml
450  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 23607_devprov_mermsemr_com.yml
451  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 57257_devprov_mermsemr_com.yml
452  ansible-playbook   --vault-password-file secrets.pass  --key-file ~/.ssh/ansible_worker -i inventory 63404_devprov_mermsemr_com.yml
453  history
454  history |grep ssh
455  history >> ALLcc.txt


