Hi Yogesh, All your videos are really nice and way to understand. Thanks for such knowledge sharing sessions. I just want to understand how we can encrypt and use the password which is to be added on multiple users with same playbook.
Hi yogesh , Your videos on Ansible are very detailed and simple. Thank you so much for taking the time in making the videos. If there is a git repository where I can download the consolidated list of play books u created, it would be of great help to work with them and practice ansible. Thank you so much in advance.
Nice tutorial..... Let's suppose i have a list of users in excel file and i need to add those users ..... how to call/link that excel into the playbook .... i know we can create a yml file and copy all users there and we can add that file into playbook, however i have an excel file .... how would u do it..
Sorry for a very late reply. You can use this community module to read xls file. Then regular user module can handle user creation. docs.ansible.com/ansible/latest/collections/community/general/read_csv_module.html
Hi Yogesh, Excellent job you have been doing for us. Thanks a lot and it's really helpful. Please share the playbook. Also please post some videos for creating VPC in AWS.
Hi, Can you please help me I am getting below error : or how to solve ERROR! We were unable to read either as JSON nor YAML, these are the errors we got from each: JSON: No JSON object could be decoded Syntax Error while loading YAML. did not find expected key The error appears to be in '/etc/ansible/user3.yml': line 33, column 4, but may be elsewhere in the file depending on the exact syntax problem. The offending line appears to be: # this task generate public keys for user - name: generate ssh keys for a user ^ here
Hello Mr. Vilas, Personally I will prefer like write playbook yourself with reference to the demo I gave in the video. It will help you to understand the YAML formatting..
Hello, I am unable to find this playbook. I suggest you writing this at your own after understanding. This will help you to learn syntax and indentation. Please let me know how you go with this. Thanks
Hi Yogesh, i did same as above copied the keys in all the machines, but when try to create user in remote machine, i used become, its giving error "Shared connection to node1 closed. ", "module_stdout": "sudo: a password is required " " please help me with this - hosts: client1 remote_user: ansible become: yes become_method: sudo gather_facts: no vars: passwd: "{{'password' | password_hash('sha512') }}" tasks: - name: creating user user: name=username password={{ passwd }} state=present
Hi how I can set password without using variables and openssl method .. i want to give direct password to user in task while creating user... it is possible?
Hi Yogesh, Could you please advise how to do privileged access to any user using ansible. A brief explanation and also whether should it requires any parameter changes in ansible.cfg file. I have written a playbook , kindly advise for it. --- - hosts: 192.168.0.55 remote_user: Atanu become: true become_method: su tasks: - name: start the nfs service service: name: nfs enabled: yes state: started
+Atanu Debnath become_method should be sudo and on your tater hosts add sudo rule for your user to get equivalent of root or command you want to execute
Thanks Chandan, unfortunately I don’t have Git repo. I would write it at my own to get understanding on the YAML formatting and get more familiarity with ansible.
+sushmita suren for linux targets. If you want to create windows users , use win_user module. More info. docs.ansible.com/ansible/latest/win_user_module.html
Hi Yogesh, nice tutorial, but let's say that l don't want to use a variable, l just wanna use password: 123456? The reason is that l wanna create users with a password and give this username and password to the client
Hi Yogesh,
This is excellent for freshers because everything you share with us is simple and knowledgeable.
Thanks for the feedback
Can you add the playbook to the description area of the video or make it downloadable via Dropbox etc.
Hi Yogesh,
All your videos are really nice and way to understand. Thanks for such knowledge sharing sessions.
I just want to understand how we can encrypt and use the password which is to be added on multiple users with same playbook.
thanks Yogesh for this good video
Hi yogesh ,
Your videos on Ansible are very detailed and simple. Thank you so much for taking the time in making the videos. If there is a git repository where I can download the consolidated list of play books u created, it would be of great help to work with them and practice ansible. Thank you so much in advance.
Apologies Saileah. I don’t have git repo.
Nice tutorial..... Let's suppose i have a list of users in excel file and i need to add those users ..... how to call/link that excel into the playbook .... i know we can create a yml file and copy all users there and we can add that file into playbook, however i have an excel file .... how would u do it..
Sorry for a very late reply. You can use this community module to read xls file. Then regular user module can handle user creation.
docs.ansible.com/ansible/latest/collections/community/general/read_csv_module.html
Hi Yogesh,,, Very good one ..
thanks for feedback. cheers
Hi Yogesh,
Excellent job you have been doing for us. Thanks a lot and it's really helpful. Please share the playbook. Also please post some videos for creating VPC in AWS.
thanks for feedback :)
thanks for feedback ,will post videos on VPC soon :)
Awesome tutorial, thank you
Good one Yogesh
Hi, Can you please help me
I am getting below error : or how to solve
ERROR! We were unable to read either as JSON nor YAML, these are the errors we got from each:
JSON: No JSON object could be decoded
Syntax Error while loading YAML.
did not find expected key
The error appears to be in '/etc/ansible/user3.yml': line 33, column 4, but may
be elsewhere in the file depending on the exact syntax problem.
The offending line appears to be:
# this task generate public keys for user
- name: generate ssh keys for a user
^ here
Hell Mr. Yogesh,
It's very nice demo for User Managment. I would appriciate if could share playbook for the same. Thanks.
Hello Mr. Vilas, Personally I will prefer like write playbook yourself with reference to the demo I gave in the video. It will help you to understand the YAML formatting..
Great video Yogesh! Can I get a copy of that playbook, please?
Hi Yogesh, could you please share this playbook to me, thanks for making awesome video on playbook
Hello, I am unable to find this playbook. I suggest you writing this at your own after understanding. This will help you to learn syntax and indentation.
Please let me know how you go with this.
Thanks
Good stuff.. Thanks alot.
Very nice video.
Can u share me the playbook?
Hi Shatrujeet, I don’t think I have playbook now. You May write your playbook after watching the video. Writing it yourself will be great fun. Cheers
Hi Yogesh, i did same as above copied the keys in all the machines, but when try to create user in remote machine, i used become, its giving error "Shared connection to node1 closed.
", "module_stdout": "sudo: a password is required
" " please help me with this
- hosts: client1
remote_user: ansible
become: yes
become_method: sudo
gather_facts: no
vars:
passwd: "{{'password' | password_hash('sha512') }}"
tasks:
- name: creating user
user: name=username password={{ passwd }} state=present
Hi how I can set password without using variables and openssl method .. i want to give direct password to user in task while creating user... it is possible?
It took me 2 mins to learn that you are saying secondary group...
Hi Mr. Mehta,
May i ask if you could please send myself on a copy of your playbook please.
Hi Yogesh thanks for this video can you plz share the playbook
Hi Yogesh,
Can please share the playbook ....
Thanx in Advance .
Show how to do normal passowrd reset for any user on any server using ansible.
Hi sir, wat is the use of become_user. If I don't write this what will be the result?
Hello Dhruv, if you don’t specify become_user, the ansible commands or playbook will not run with sudo rights.
@@YogeshMehta thanks
Hi Yogesh,
Could you please advise how to do privileged access to any user using ansible.
A brief explanation and also whether should it requires any parameter changes in ansible.cfg file.
I have written a playbook , kindly advise for it.
---
- hosts: 192.168.0.55
remote_user: Atanu
become: true
become_method: su
tasks:
- name: start the nfs service
service:
name: nfs
enabled: yes
state: started
+Atanu Debnath become_method should be sudo and on your tater hosts add sudo rule for your user to get equivalent of root or command you want to execute
I need this playbook sir. Can you please share the playbook with me.
Thank you.
Thanks Chandan, unfortunately I don’t have Git repo. I would write it at my own to get understanding on the YAML formatting and get more familiarity with ansible.
Hello sir, in the add_several_users tag, what is the use of that password you have given?
Thank you in advance. All videos are superb sir.
+Sudhir Nikhade password is encrypted password and I generated before.
Hai great. Please share the playbook
thanks for the feedback..please share your email id..
could you possibly save typing by pasting file?
Yes sure. Will follow in future videos
This is for Linux to Linux machine or this playbook wil work for linux to Windows too?
+sushmita suren for linux targets. If you want to create windows users , use win_user module. More info. docs.ansible.com/ansible/latest/win_user_module.html
Can you share the playbook
Hi Yogesh, nice tutorial, but let's say that l don't want to use a variable, l just wanna use password: 123456? The reason is that l wanna create users with a password and give this username and password to the client
share me the playbook plz
Why everybody there in comments are asking for a playbook? Are those people so lazy just simply to write own pb?
Thanks for helping
Please can I have your email?