# How to create ssl certs of our own ? using letsencrypt or mkcert

**URL:** <https://forums.percona.com/t/how-to-create-ssl-certs-of-our-own-using-letsencrypt-or-mkcert/15364>\
**Category:** Uncategorized\
**Tags:** community, pmm, percona, new-release\
**Created:** [April 23, 2022, 5:31pm UTC](https://forums.percona.com/t/how-to-create-ssl-certs-of-our-own-using-letsencrypt-or-mkcert/15364 "2022-04-23T17:31:44Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kotha\_Sambashiva\_Rao](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/kotha_sambashiva_rao/32/6315_2.png) [@Kotha\_Sambashiva\_Rao](https://forums.percona.com/u/Kotha_Sambashiva_Rao)\
**Post date:** [April 23, 2022, 5:31pm UTC](https://forums.percona.com/t/how-to-create-ssl-certs-of-our-own-using-letsencrypt-or-mkcert/15364/1 "2022-04-23T17:31:44Z")

</div>

Hi  
i have generated certs using openssl and copied to /srv/nginx folder of container but its not working  
Can you pls let me know the exact commands to generate certs and paste in container.

---

<div class="post-metadata">

**Author:** ![matthewb](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/matthewb/32/34_2.png) [@matthewb](https://forums.percona.com/u/matthewb)\
**Post date:** [April 24, 2022, 3:02am UTC](https://forums.percona.com/t/how-to-create-ssl-certs-of-our-own-using-letsencrypt-or-mkcert/15364/2 "2022-04-24T03:02:01Z")

</div>

Check out this JIRA: [[PMM-1566] Add LetsEncrypt support to PMM Server - Percona JIRA](https://jira.percona.com/browse/PMM-1566)

---

<div class="post-metadata">

**Author:** ![Kotha\_Sambashiva\_Rao](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/kotha_sambashiva_rao/32/6315_2.png) [@Kotha\_Sambashiva\_Rao](https://forums.percona.com/u/Kotha_Sambashiva_Rao)\
**Post date:** [April 24, 2022, 11:02am UTC](https://forums.percona.com/t/how-to-create-ssl-certs-of-our-own-using-letsencrypt-or-mkcert/15364/3 "2022-04-24T11:02:52Z")

</div>

certbot certonly --agree-tos --register-unsafely-without-email --webroot -w /usr/share/pmm-server -d [pmm-server.mycompany.com](http://pmm-server.mycompany.com)

when i try to use this command getting error as not authorised or some issue @matthewb

---

<div class="post-metadata">

**Author:** ![matthewb](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/matthewb/32/34_2.png) [@matthewb](https://forums.percona.com/u/matthewb)\
**Post date:** [April 24, 2022, 1:38pm UTC](https://forums.percona.com/t/how-to-create-ssl-certs-of-our-own-using-letsencrypt-or-mkcert/15364/4 "2022-04-24T13:38:49Z")

</div>

Can’t assist you without seeing your commands and the output.

---

<div class="post-metadata">

**Author:** ![Kotha\_Sambashiva\_Rao](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/kotha_sambashiva_rao/32/6315_2.png) [@Kotha\_Sambashiva\_Rao](https://forums.percona.com/u/Kotha_Sambashiva_Rao)\
**Post date:** [April 24, 2022, 2:49pm UTC](https://forums.percona.com/t/how-to-create-ssl-certs-of-our-own-using-letsencrypt-or-mkcert/15364/6 "2022-04-24T14:49:50Z")

</div>

Somehow i tried with Openssl and copied certs to /srv/nginx but still getting “NOT SECURE” @matthewb

 ![image-20220424-122507](https://us1.discourse-cdn.com/flex019/uploads/percona1/original/2X/f/f345cba698f7638f63aeb22b6f829940e6e9c6dc.png)

---

<div class="post-metadata">

**Author:** ![matthewb](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/matthewb/32/34_2.png) [@matthewb](https://forums.percona.com/u/matthewb)\
**Post date:** [April 24, 2022, 6:21pm UTC](https://forums.percona.com/t/how-to-create-ssl-certs-of-our-own-using-letsencrypt-or-mkcert/15364/7 "2022-04-24T18:21:26Z")

</div>

That certificate is not a LetsEncrypt certificate. You simply replaced PMM’s self-signed cert with your own self-signed cert and your browser does not trust it.

---

<div class="post-metadata">

**Author:** ![Sanjana\_Chandrasheka](https://avatars.discourse-cdn.com/v4/letter/s/34f0e0/32.png) [@Sanjana\_Chandrasheka](https://forums.percona.com/u/Sanjana_Chandrasheka)\
**Post date:** [June 9, 2022, 7:38am UTC](https://forums.percona.com/t/how-to-create-ssl-certs-of-our-own-using-letsencrypt-or-mkcert/15364/8 "2022-06-09T07:38:19Z")

</div>

@matthewb , I have created my own certs and my pmm-server web browser trusts it too, it says ‘connection is secure’ but the problem I am facing is when I register pmm-client with pmm-server I get

```auto
Failed to register pmm-agent on PMM Server: Post "https://XXXXX:443/v1/management/Node/Register": x509: certificate signed by unknown authority.

```

whats the issue here?  
Thanks

---

<div class="post-metadata">

**Author:** ![matthewb](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/matthewb/32/34_2.png) [@matthewb](https://forums.percona.com/u/matthewb)\
**Post date:** [June 9, 2022, 3:01pm UTC](https://forums.percona.com/t/how-to-create-ssl-certs-of-our-own-using-letsencrypt-or-mkcert/15364/9 "2022-06-09T15:01:05Z")

</div>

You need to import your own certs into the servers list of acceptable certs. When pmm-client connects to your pmm-server, the client’s OS does not recognize the SSL.

---

<div class="post-metadata">

**Author:** ![Sanjana\_Chandrasheka](https://avatars.discourse-cdn.com/v4/letter/s/34f0e0/32.png) [@Sanjana\_Chandrasheka](https://forums.percona.com/u/Sanjana_Chandrasheka)\
**Post date:** [June 9, 2022, 4:33pm UTC](https://forums.percona.com/t/how-to-create-ssl-certs-of-our-own-using-letsencrypt-or-mkcert/15364/10 "2022-06-09T16:33:15Z")

</div>

okay , thank you for clarifying it.
