flant / ovpn-admin

Simple web UI to manage OpenVPN users.
Apache License 2.0
1.39k stars 261 forks source link

Fatal: /mnt/easyrsa/pki/ta.key: no such file or directory #116

Closed PePoDev closed 2 years ago

PePoDev commented 2 years ago

Full log of ovpn-admin container

2022/04/21 12:05:54 WARNING: openvpn mgmt interface for main is not reachable by addr 127.0.0.1:8989
2022/04/21 12:05:54 openssl x509 -in /mnt/easyrsa/pki/ca.crt -noout -enddate | awk -F "=" {'print $2'}
2022/04/21 12:05:54 Runnnig in debug mode
2022/04/21 12:05:54 Runnnig in verbose mode
2022/04/21 12:05:54 Bind: http://0.0.0.0:8080
2022/04/21 12:06:13 date +%Y-%m-%d\ %H:%M:%S && cd /mnt/easyrsa && easyrsa build-client-full pepo nopass
2022/04/21 12:06:13 2022-04-21 12:06:13
Using SSL: openssl OpenSSL 1.1.1n  15 Mar 2022
Generating a RSA private key
.....................................+++++
...............................................................+++++
writing new private key to '/mnt/easyrsa/pki/easy-rsa-22.LpgMjg/tmp.lFAiMM'
-----
Using configuration from /mnt/easyrsa/pki/easy-rsa-22.LpgMjg/tmp.nHLBgo
Check that the request matches the signature
Signature ok
The Subject's Distinguished Name is as follows
commonName            :ASN.1 12:'pepo'
Certificate is to be certified until Jul 24 12:06:13 2024 GMT (825 days)

Write out database with 1 new entries
Data Base Updated

2022/04/21 12:06:13 INFO: user created: pepo
2022/04/21 12:06:14 WARNING: hosts for pepo
 [{127.0.0.1 7777 tcp}]
2022/04/21 12:06:14 open /mnt/easyrsa/pki/ta.key: no such file or directory
pashcovich commented 2 years ago

ovpn-admin needs to have access to some files from openvpn server as well. do you have running openvpn-server container with shared directories?

PePoDev commented 2 years ago

It worked after restart the failed container

FYI, I have run it with docker-compose. The file system should be already shared between two containers.