Re: [ansible-project] Trying to create a new user and password for server login . SSH permission denied error.

2018-04-13 Thread Biswadip Dutta
This

might
be helpful for you

Regards,
Biswadip Dutta

On Fri, Apr 13, 2018 at 2:38 AM, POOJA VENKATESH <
poojavenkateshre...@gmail.com> wrote:

> Hi,
>
>
> I am trying to create a new user and password for the server login. The
> user is created in /etc/passwd and also I can see the password entry in
> /etc/shadow however when I try to ssh through the new user I cannot login
> into the server. What steps are missing in the following code?
>
>
>
> ---
> - hosts: local host
>   vars:
> username: random
>   vars_prompt:
> - name: "user_passwd"
>   prompt: "Enter a password for the user"
>   private: yes
>   tasks:
> - name: Add a new user
>   become: yes
>   user:
> name: '{{ username }}'
> shell: /bin/bash
> group: sudo
> state: present
> createhome: yes
>
>
>
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Ansible Project" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to ansible-project+unsubscr...@googlegroups.com.
> To post to this group, send email to ansible-project@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/ansible-project/CAAGG3SAALojkjpgNW%3DcEUt7_wi%
> 2Bdd40CGc_-3LiYJTtYUKaTPA%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAEC%3DuXku1arnNc-R9L37yxrcwk-s7LbNG1OwR1pGMbDDc_4WwQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[ansible-project] Trying to create a new user and password for server login . SSH permission denied error.

2018-04-12 Thread POOJA VENKATESH
Hi,


I am trying to create a new user and password for the server login. The
user is created in /etc/passwd and also I can see the password entry in
/etc/shadow however when I try to ssh through the new user I cannot login
into the server. What steps are missing in the following code?



---
- hosts: local host
  vars:
username: random
  vars_prompt:
- name: "user_passwd"
  prompt: "Enter a password for the user"
  private: yes
  tasks:
- name: Add a new user
  become: yes
  user:
name: '{{ username }}'
shell: /bin/bash
group: sudo
state: present
createhome: yes

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CAAGG3SAALojkjpgNW%3DcEUt7_wi%2Bdd40CGc_-3LiYJTtYUKaTPA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


[ansible-project] Trying to create a new user and password for server login . SSH permission denied error.

2018-04-12 Thread poojavenkateshreddy
Hi, 


I am trying to create a new user and password for the server login. The 
user is created in /etc/passwd and also I can see the password entry in 
/etc/shadow however when I try to ssh through the new user I cannot login 
into the sever. What steps are missing in the following code.



---
- hosts: local host
  vars:
username: random
  vars_prompt:
- name: "user_passwd"
  prompt: "Enter a password for the user"
  private: yes
  tasks:
- name: Add a new user
  become: yes
  user:
name: '{{ username }}'
shell: /bin/bash
group: sudo
state: present
createhome: yes
   









-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/e7fb364f-93b6-4407-9865-f9fe6ca972af%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.