Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Using on the proxmox host (with Dynu DNS)

Proxmox +

Using on the proxmox host to generate Letsencrypt certificates

With this we show how to use instead of the original Letsencrypt interface. is just a Bash script that can run on pretty much any *nix environment.
It is quite simple but also quite powerfull.

In this guide I will use the cheap and good Dynu service to configure a domain.
Using the DNS allows you to completely bypass the need to point the port 80 of the domain to the machine.

As a matter of fact, there is absolutely ZERO NETWORK configuration needed to generate the certificate.
All you need is curl/wget and outbound internet connection.

The magic happens at the DNS side and you receive the certificate ready to use.

There are many other DNS providers supported (Goddady, etc).

This may also solve the Armageddon Warnings the Browsers show for self-signed certificates.
Just need to make sure the certificate domain name points to the correct IP on the local network (could add to router DNS).

DNS Requirements

If you want to use your DNS provider, you will need it to have your domain registered with them, obviouosly.
You may also need to add the subdomain to their DNS records. On Dynu I just add it as a Dynamic DNS entry.

Your DNs provider should also be supported by, or you will need to create a DNS file for your system's API.
There are a lot of supported providers though, should not happen easily.

Run Requirements

ssh into proxmox host (change IP address)

ssh root@

We will use git, install it

apt-get update
apt-get install git


lets create a work folder

cd /root
mkdir workfolder
cd workfolder

download with git

git clone ''

Install with account (change email address)

./ --install --accountemail ""

If all went fine it was installed to /root/ and it has also set a crontab job.
List crontab to check

# crontab -l
24 0 * * * "/root/"/ --cron --home "/root/" > /dev/null

At this point is fully operational and can be used in any mode of operation.

Dynu config

Go to the installation folder

cd /root/

Edit the account.conf file and add your Dynu credentials

nano account.conf
# vi account.conf    # use vi if your prefer

You need to have an API subscription with Dynu and then generate a ClentId / Secret.
The account.conf will look something like this:


If all info is correct, you can then use the Dynu API with to generate the certificates.

Generate certificate through Dynu

We will use the default folder to generate and then a second call to install the certs.

  • This will have a 120s wait for the DNS to change and apply
  • One of the good benefits of Dynu is that they hav 90s/120s TTL

To issue a certificate through Dynu you can use

./ --debug --issue --dns dns_dynu -d

If you want to test using the stage server first, just add --test

./ --debug --issue --dns dns_dynu -d --test

But then you will need to use --force to ovewrite the test cert

./ --debug --issue --dns dns_dynu -d --force

Install generated certificates

If all went fine and you have valid certificates, you can install them on the PVE interface.
Please change the subdomain

./ --debug --installcert -d \
--keypath /etc/pve/local/pveproxy-ssl.key \
--fullchainpath /etc/pve/local/pveproxy-ssl.pem \
--reloadcmd "systemctl restart pveproxy"

In Single-line

./ --debug --installcert -d --keypath /etc/pve/local/pveproxy-ssl.key --fullchainpath /etc/pve/local/pveproxy-ssl.pem --reloadcmd "systemctl restart pveproxy"

Local DNS config

You may need to tell your router/gateway to point the domain the to LOCAL IP instead of the internet IP so you can use the domain to access proxmox locally.

Or else you can edit you /etc/hosts or C:\Windows\system32\etc\hosts file for a local config.

A host config would look like: IP <space> domain

This comment has been minimized.

Copy link

@yuriw yuriw commented Aug 26, 2020

This is great.
If you use proxmox WebGUI to add ACME DNS Plugin challenge. What and in what format would you use in the API Data field (see pic)?



This comment has been minimized.

Copy link

@adcurtin adcurtin commented Sep 8, 2020

in the api data field, you just put the env vars you need for your api. for dynu:


it will be base64 encoded in
/etc/pve/priv/acme/plugins.cfg :

dns: test-fake
	api dynu
	data RHludV9DbGllbnRJZD0ieHh4eHh4eHgteHh4eC14eHh4LXh4eHgteHh4eHh4eHh4eHh4IgpEeW51X1NlY3JldD0ieXl5eXl5eXl5eXl5eXl5eXl5eXl5eXl5eSI=

This comment has been minimized.

Copy link
Owner Author

@tavinus tavinus commented Sep 9, 2020

Never used the WebGUI for this. Seems simple enough with @adcurtin 's answer.


This comment has been minimized.

Copy link

@yuriw yuriw commented Sep 9, 2020

Exact format should be without quotes -

Dynu_Secret= 1234567890abc
Dynu_Token= 1234567890abc


This comment has been minimized.

Copy link
Owner Author

@tavinus tavinus commented Dec 2, 2020

Today I used the web interface for the first time to do this.

Here is how I did it:

0. Install Acme account (optional?)

Datacenter > ACME > Accounts > Add
Choose a name and an e-mail.

1. Install your ACME DNS Plugin

Datacenter > ACME > Challenge Plugins > Add

  • Plugin ID: dynu
  • DNS API: dynu
  • API Data: (remove quotes)


You can adjust to your liking or another DNS provider.

2. Add entries to Dynu

  • Add alias or subdomain pointing to you desired subdomain (pve-mynode.mydomain.tld)

  • Add CAA DNS Record
    This authorizes letsencrypt to create certificates do this subdomain

3. Create certificate

YourNode > System > Certificates > ACME > Add

  • Challenge Type: DNS
  • Plugin: dynu
  • Domain: pve-mynode.mydomain.tld (same as node hostname)


After creating it, select it and click Order Certificates Now to generate and install the certificates.

Everything went smoothly and proxmox installed and reloaded the main interface with the certificates installed.

Now just need to point the domain to the IP internally (or edit your local hosts file).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment