Advertisement
sandervanvugt

RHCE day1 june21

Jun 8th, 2021
218
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.60 KB | None | 0 0
  1. ansible@control webservers]$ history
  2. 1 history
  3. 2 exit
  4. 3 cd rhce8-live/
  5. 4 ./countdown 12
  6. 5 cat todo.txt
  7. 6 id
  8. 7 sudo ls /root
  9. 8 sudo yum install git vim -y
  10. 9 which dnf
  11. 10 which yum
  12. 11 ls -l /usr/bin/yum
  13. 12 git clone https://github.com/sandervanvugt/rhce8-live
  14. 13 git clone https://github.com/sandervanvugt/rhce8-book
  15. 14 ls
  16. 15 cd rhce8live
  17. 16 cd rhce8-live
  18. 17 ls
  19. 18 cd ../rhce8-book/
  20. 19 ls
  21. 20 sudo yum install epel-release
  22. 21 sudo yum install ansible
  23. 22 sudo -i
  24. 23 ssh-keygen
  25. 24 ls .ssh
  26. 25 ls ~/.ssh
  27. 26 ssh-copy-id ansible1
  28. 27 ssh-copy-id ansible2
  29. 28 ssh ansible1
  30. 29 ssh ansible2
  31. 30 ansible --version
  32. 31 cd
  33. 32 vim todo.txt
  34. 33 history
  35. 34 ls
  36. 35 cd rhce8-live/
  37. 36 ls
  38. 37 cd lesson2/
  39. 38 ls
  40. 39 vim inventory
  41. 40 vim /etc/ansible/hosts
  42. 41 cd ..
  43. 42 ansible -i inventory all --list-hosts
  44. 43 ls
  45. 44 cd lesson2/
  46. 45 ls
  47. 46 ansible -i inventory all --list-hosts
  48. 47 ansible file --list-hosts
  49. 48 cat inventory
  50. 49 ansible db --list-hosts
  51. 50 cat ansible.cfg
  52. 51 grep -i inventory /etc/ansible/ansible.cfg
  53. 52 ansible -i inventory ungrouped --list-hosts
  54. 53 cat inventory
  55. 54 ls
  56. 55 vim pascal-new.py
  57. 56 ./pascal-new.py --list
  58. 57 which python3
  59. 58 vim pascal-new.py
  60. 59 ./pascal-new.py --list
  61. 60 vim pascal.py
  62. 61 ./pascal.py --list
  63. 62 ansible --version
  64. 63 cd ..
  65. 64 ansible --version
  66. 65 cd -
  67. 66 vim ansible.cfg
  68. 67 vim /etc/ansible/ansible.cfg
  69. 68 cat /etc/redhat-release
  70. 69 ansible all -m command -a "useradd lisa"
  71. 70 cat inventory
  72. 71 ansible all -m command -a "useradd lisa" -K
  73. 72 ansible all -m user -a "name=lisa" -K
  74. 73 ansible all -m command -a "id lisa"
  75. 74 ansible all -m command -a "id lisa" -K
  76. 75 history
  77. 76 ansible all -m command -a "rpm -qa | grep ssh" -K
  78. 77 ansible all -m shell -a "rpm -qa | grep ssh" -K
  79. 78 ansible all -m raw -a "rpm -qa | grep ssh" -K
  80. 79 ansible-doc copy
  81. 80 ansible all -m copy -a "src=/etc/sudoers.d/ansible dest=/etc/sudoers.d/ansible" -K
  82. 81 ls -l /etc/sudoers.d/
  83. 82 sudo ls -l /etc/sudoers.d/
  84. 83 sudo ansible all -m copy -a "src=/etc/sudoers.d/ansible dest=/etc/sudoers.d/ansible" -K
  85. 84 sudo cp /etc/sudoers.d/ansible /tmp/ansible
  86. 85 ansible all -m copy -a "src=/tmp/ansible dest=/etc/sudoers.d/ansible" -K
  87. 86 ansible all -m user -a "name=betty"
  88. 87 history
  89. 88 ansible-doc -l
  90. 89 ansible-doc user
  91. 90 ansible-doc -l
  92. 91 nsible-doc -lqq
  93. 92 reset
  94. 93 ansible-doc -l | wc
  95. 94 ansible all -m ping
  96. 95 ansible all -m service -a "name=httpd state=started"
  97. 96 ansible all -m copy -a 'content="ansible ALL=(ALL) NOPASSWD: ALL" dest=/etc/sudoers.d/ansible'
  98. 97 ansible all -m command -a "cat /etc/sudoers.d/ansible"
  99. 98 ANSIBLE_KEEP_REMOTE_FILES=1 ansible all -m ping
  100. 99 ANSIBLE_KEEP_REMOTE_FILES=1 ansible -vvvv all -m ping
  101. 100 ssh ansible2
  102. 101 exit
  103. 102 cd rhce8-live/
  104. 103 history
  105. 104 ansible all -m copy -a 'content="ansible ALL=(ALL) NOPASSWD: ALL" dest=/etc/sudoers.d/ansible'
  106. 105 cd lesson2/
  107. 106 ansible all -m copy -a 'content="ansible ALL=(ALL) NOPASSWD: ALL" dest=/etc/sudoers.d/ansible'
  108. 107 history
  109. 108 vim ~/.vimrc
  110. 109 ls
  111. 110 cd ../lesson4
  112. 111 ls
  113. 112 vim vsftpd.yml
  114. 113 ansible-playbook vsftpd.yml
  115. 114 cat vsftpd.yml
  116. 115 ls
  117. 116 ansible-playbook vsftpd-err.yml
  118. 117 vim vsftpd-err.yml
  119. 118 ansible-playbook vsftpd-err.yml
  120. 119 vim vsftpd-err.yml
  121. 120 ansible-playbook -v vsftpd-err.yml
  122. 121 ansible-playbook -vv vsftpd-err.yml
  123. 122 ansible-playbook -vvvv vsftpd-err.yml
  124. 123 ../countdown 12
  125. 124 ls
  126. 125 vim uninstall-httpd.yml
  127. 126 sudo yum provides */ansible-lint
  128. 127 sudo yum install python3-ansible-lint
  129. 128 sudo yum repolist
  130. 129 cd ../lesson5/
  131. 130 ls
  132. 131 vim user.yml
  133. 132 ansible-playbook user.yml
  134. 133 vim inventory
  135. 134 ansible-playbook user.yml -e user=bob
  136. 135 ansible-config --help
  137. 136 ansible-config view
  138. 137 ansible-config list
  139. 138 ansible-config dump
  140. 139 ls
  141. 140 cd webservers/
  142. 141 ls
  143. 142 vim site.yml
  144. 143 ls group_vars/
  145. 144 cat group_vars/lamp
  146. 145 cat inventory
  147. 146 ansible-playbook site.yml
  148. 147 vim site.yml
  149. 148 ls
  150. 149 mkdir host_vars
  151. 150 cat inventory
  152. 151 vim host_vars/ansible1.example.com
  153. 152 cat group_vars/lamp
  154. 153 ansible-playbook site.yml
  155. 154 history
  156.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement