Stouts / Stouts.openvpn

Ansible role to install and configure OpenVPN server
MIT License
287 stars 207 forks source link

'auth-client.sh #167

Closed mikysal78 closed 4 years ago

mikysal78 commented 4 years ago

Options error: --auth-user-pass-verify script fails with 'auth-client.sh': No such file or directory (errno=2) Options error: Please correct this error.

My playbook

- hosts: openvpn
  become: "{{ become | default('yes') }}"
  roles:
    - Stouts.openvpn
  vars:
    openvpn_dev: vpnbas
    openvpn_clients: []
    openvpn_max_clients: 256
    openvpn_key_country: IT
    openvpn_key_province: MT
    openvpn_key_city: Matera
    openvpn_key_org: Ninux Basilicata
    openvpn_key_email: mikysal78@gmail.com
    openvpn_key_size: 2048
    openvpn_use_pam: no
    openvpn_cipher: none
    openvpn_keepalive: "5 60"
    openvpn_topology: subnet
    openvpn_server: 10.27.253.0 255.255.255.0
    openvpn_simple_auth: yes
    openvpn_simple_auth_password: mypass
    openvpn_bridge:
        address: 10.27.253.1
        netmask: 255.255.255.0
        network: 10.27.253.0
        broadcast: 10.27.253.255
        dhcp_start: 10.27.253.2
        dhcp_end: 10.27.253.254
    openvpn_server_options:
        - "dev-type tap"
        - "client-to-client"
        - "username-as-common-name"
        - "client-cert-not-required"
        - "tls-server"
        - "fast-io"
mikysal78 commented 4 years ago

Fix edit task simple.yml (Line 8)...

- name: Setup simple authentication
  template:
    src: authentication/auth-client.sh.j2
    dest: "{{ openvpn_etcdir }}/auth-client.sh"
    mode: 0o755
  when: openvpn_simple_auth and openvpn_simple_auth_password
  notify: openvpn restart