What the two script slots do
| Slot | When it runs | What it is for |
|---|---|---|
| During issuance script | While the certificate is being validated | Automates validation. The typical case is adding the validation CNAME record through your DNS provider's API. With Auto Renew on, you no longer add a record by hand at every renewal. |
| Post-issuance script | After every successful issue, renewals included | Deploys the new certificate: imports it into a cloud certificate service, writes it to another server and reloads the service, or makes a CDN switch to it. It runs again after each renewal, so the copy in the cloud or on the other server stays current. |
Both slots are optional, and each takes one script. Once you pick a script, the parameters it needs appear below it. For the rest of the Add Certificate dialog (domain, validation method, storage paths, auto renew and so on), see Free certificates: request, validate and bind to a site.
- Issuing script
- Runs during validation and helps the CA validate, for example by adding a DNS record.
- Post-issuance script
- Runs after the certificate is issued and after every renewal, and sends the new certificate somewhere else.
- API token / access key
- A user name and password that a cloud service gives to programs. The script uses it to call the service's API (add a DNS record, upload a certificate).
-
Open Add Certificate and find Automation Scripts
In the left menu go to Domain Management → Certificate Management and click Add Certificate at the top right. At the bottom of the dialog, Automation Scripts has two dropdowns: During issuance script on the left and Post-issuance script on the right, both showing Select a script by default.

-
Pick a script and fill in its parameters
After you pick a script, a one-line description and its parameters appear under the dropdown (required ones are marked with a red *). The screenshot shows the post-issuance script LNMP Nginx Reload, which needs no parameters and only shows its description.

Read this first: keys go into the panel (stored encrypted, shown masked); scripts that reach other machines need approval
Scripts run as root on the server where Nodekeeper runs, and any member with the permission can choose any script in shell/ssl on the certificate page. So two things need protecting: cloud account keys, and scripts that reach other machines or paths.
- Cloud keys are typed straight into the certificate form. In the AWS ACM, Tencent Cloud and Baidu Cloud CDN (Secret Key) scripts the key inputs are password fields: not echoed, and the browser does not autofill them. The key is stored encrypted in Nodekeeper's database, shown afterwards only as
******(the audit log masks it too), and handed to the script through an environment variable, never on the command line, so other users on the machine cannot see it. You do not create any credential file on the server. - Give the key least privilege. Use a dedicated sub-account: AWS gets only the permission to import certificates and Tencent Cloud only SSL certificate permissions (the examples below do exactly that); never use the root account's keys.
- Scripts that reach other machines or paths need administrator approval. SSH deploy and FTP upload are examples: such a script declares "approval required" in its header, and every parameter set must be approved once by an administrator with the approval permission, in the panel, without logging in to the server. If the certificate, its owner, its domains, the script or any parameter changes, it needs approval again. Scripts that only call a cloud API (AWS, Tencent Cloud, Baidu Cloud, Cloudflare and so on) need no approval.
- The run details are in the panel. In the certificate details, the Post-issue script section shows the approval state and the last run: time, result, exit code and the output (the last ~4 KiB, keys masked).
The approval flow for SSH deploy is in "Post-issuance script 3" below; how to write your own script and make it require approval is in the "SSL script development guide" at the end.
- Least privilege
- Give a key only the rights this job needs, such as importing certificates or editing one domain's DNS. If it leaks, the damage stays small.
- Approval
- An administrator checks the script and every parameter in the panel; the script only runs after Approve and run.
- Masking
- Replacing a secret with
******before it is shown or recorded: in the panel, the audit log and the run output. - Environment variable
- A name=value pair handed to a program that only the program itself sees, unlike command-line arguments, which other users on the machine can see.
Issuing script example: Cloudflare adds the DNS validation record
If your domain's DNS is hosted at Cloudflare, use the Cloudflare DNS validation script (shown as "Cloudflare DNS验证" in the panel). Nodekeeper adds the validation CNAME record to Cloudflare itself. The script first looks up the existing records with the same name and type in Cloudflare and deletes them, then adds the new validation record; on renewals it swaps the record the same way. After validation the record stays in Cloudflare and is not deleted automatically. This script supports DNS validation only. For other DNS providers, see "The other bundled scripts" below. For the rest of the Add Certificate dialog, see Free certificates: request, validate and bind to a site.
The token input of this script is an ordinary field (not a password field), so give the token below DNS edit rights on this one domain only, and don't use the global API key.
-
Create an API token in Cloudflare
Sign in to Cloudflare, open
dash.cloudflare.com/profile/api-tokens, click Create Token, and use the Edit zone DNS template or set the permissions yourself:- Zone - DNS - Edit (lets it change DNS records);
- Zone - Zone - Read (used to look up the Zone ID when you leave it blank);
- under Zone Resources, pick only the domain you are issuing for.
Copy the token after creating it. It is shown only once, so store it safely.
-
Choose DNS validation and the Cloudflare script
In Add Certificate, enter the domain and keep Free Certificate (API) selected at the top. Then, in the second Validation Method dropdown below it, choose DNS Validation (the dialog has two controls called Validation Method: the first is the certificate source, the second is the dropdown). Then in Automation Scripts, set During issuance script to Cloudflare DNS验证.

-
Enter the token
Two parameters appear under the script: Cloudflare API Token (required), where you paste the token, and Zone ID (leave blank to look it up automatically), which you can usually leave empty. Click Next Step.
After Next Step the dialog shows the CNAME record this certificate needs. With the script selected you do not add it yourself: close the dialog, and the certificate is in the list with the status Pending.

-
Click Validate and let the script add the record
In the certificate list, click Validate on this certificate, and click Validate again in the confirmation dialog. Nodekeeper asks the certificate authority to continue validation, and the script adds the validation record to Cloudflare. Done by hand, it would be the CNAME in the screenshot, but you don't need to. When the status changes from Pending to Issued, you're done. In the AWS, Tencent Cloud and SSH examples below, this step is the same.

With Auto Renew on, every renewal uses this script again: it first replaces the old record with the same name, then adds the new one and validates, with nothing for you to do.
Post-issuance script 1: import the certificate into AWS ACM (for CloudFront / ALB)
After every issue or renewal, the script imports the certificate into AWS Certificate Manager (ACM). The first time it creates the certificate; every later run re-imports into the same certificate, so the bindings on CloudFront or your load balancer stay as they are. There are four parts: create an IAM user that can only import certificates, get an access key, pick the script in the panel and enter the key there.
A few terms: ACM is AWS's certificate management service; IAM is AWS's service for users and permissions; an ARN is the unique ID AWS gives each resource, such as one certificate.
The AWS console screenshots are in Chinese. In the English console, look for the matching menu names.
-
Create a user in IAM
Sign in to the AWS console, open IAM, choose Users on the left, and click Create user at the top right.

-
Pick any user name and don't enable console access
Use a name you will recognize, such as
nk-acm-import. Leave unchecked "Provide user access to the AWS Management Console": this user is for a program and never needs to sign in to the console.
-
Don't pick permissions yet, create the user
On Set permissions, choose Attach policies directly but select no policy at all, click Next, check the user name on the review page and click Create user. In the next step we add an inline policy that only allows importing certificates.


-
Add an inline policy that only allows importing certificates
Open the user you just created, and on the Permissions tab click Add permissions → Create inline policy. Switch the editor to JSON and paste the policy below. Replace
<account ID>with your own 12-digit AWS account ID, give the policy any name, and save it.{ "Version": "2012-10-17", "Statement": [ { "Sid": "NodekeeperAcmImport", "Effect": "Allow", "Action": [ "acm:ImportCertificate", "acm:DescribeCertificate" ], "Resource": "arn:aws:acm:*:<account ID>:certificate/*" } ] }It allows only importing and describing certificates, and only for ACM certificates in your own account.
This line What it does and why "Effect": "Allow"Allows the actions listed below and nothing else. "acm:ImportCertificate"Import (or re-import) a certificate: the only permission the script needs. "acm:DescribeCertificate"Read certificate details; the script uses it to read the import back. Optional: without it the import still works and the read-back is skipped. "Resource": "arn:aws:acm:*:<account ID>:certificate/*"Only ACM certificates in your own account; no other service. Replace <account ID>with your 12-digit account ID.

-
Check that the policy is attached
After saving, the user's permissions policies list has one policy of type customer inline. That means it worked.

-
Create an access key
On the user page open the Security credentials tab (or use Create access key under Access key 1 in the summary), choose the use case Application running outside AWS, and click Next. AWS shows a recommended-alternatives notice; it is a generic hint and doesn't stop you.

-
Add a description and create it
The description tag is optional. Write what it is for so you can rotate it later, for example
Nodekeeper ACM import. Click Create access key.
-
Save the access key (the secret is shown only once)
The page says this is the only chance to view or download the secret access key. The Access key (access key ID) is the string that starts with AKIA; the Secret access key shows as stars until you click Show. You need both in the next step, so close this page only after you have entered them in the panel and saved the certificate.

The keys are only for the panel form (a password field, stored encrypted). Don't send them to anyone or paste them into chats or tickets.
-
Pick the script in the panel and enter the key
In Add Certificate, enter the domain, choose a validation method, and in Automation Scripts set Post-issuance script to AWS ACM 证书导入 / AWS ACM Certificate Import. Fill in the parameters like this:
- AWS Access Key ID: the access key you just saved (it starts with AKIA);
- AWS Secret Access Key: the secret access key. This is a password field: not echoed, stored encrypted, and shown only as
******after saving; - AWS Region: for CloudFront it must be
us-east-1(CloudFront only uses that region); for an ALB, use the region of the load balancer; - ACM certificate ARN: leave blank. The first run creates the certificate and remembers its ARN (as explained above, the ARN is the certificate's ID in AWS), and later runs import into that same one.
This script only calls AWS's API and does not touch your servers, so it needs no administrator approval.
-
Click Next Step, then Validate
As in the Cloudflare example, click Next Step to submit, click Validate on this certificate in the list, and click Validate again in the confirmation dialog. When the certificate is issued its status becomes Issued, and the post-issuance script runs automatically.


-
Check the result in ACM
In the AWS console open Certificate Manager, switch the region at the top right to US East (N. Virginia) us-east-1, and the domain is in the certificate list: type Imported, key algorithm ECDSA P 256.


-
Bind it in CloudFront or the ALB, once
The import only puts the certificate into ACM. The first time, select this certificate yourself in your CloudFront distribution or ALB listener; once is enough. After that, every renewal re-imports into the same ARN, the binding stays as it is, and you don't touch it again.
ACM shows 'In use: No' only because nothing is bound to it yet.
Post-issuance script 2: upload to Tencent Cloud SSL
After every issue or renewal, the script uploads the certificate to Tencent Cloud's SSL Certificates service, into My Certificates. Uploading the same certificate again returns the existing certificate ID, so no duplicates appear. It can also swap the old certificate on cloud resources such as a CDN for the new one (see the end of this section).
A term: CAM (Cloud Access Management) is Tencent Cloud's service for users and permissions; below you use it to create a dedicated sub-user.
The Tencent Cloud console screenshots are in Chinese. International-site accounts follow the same steps; look for the matching menu names.
-
Create a sub-user in Access Management (CAM)
Sign in to the Tencent Cloud console, go to Access Management → Users → User List and click New User. Don't use the root account's keys: create a dedicated sub-user.

-
Choose Custom Creation
On the New User page click Custom Creation.

-
Pick the type that can access resources
In step 1, Select type, choose Accessible resources and message receiving and click Next.

-
Any user name, and tick only Programmatic access
Use a name you will recognize, such as
nk-ssl-upload. Under access method tick only Programmatic access (it generates a SecretId and SecretKey), and leave Tencent Cloud console access unticked. Click Next. Tencent Cloud asks you to pass a captcha when creating the user.
-
Select only the SSL permission, and be careful not to over-select
In Set user permissions, search for and tick only QcloudSSLFullAccess (full read-write access to SSL certificates). If you also want the script to swap the certificate on your CDN, add QcloudCDNFullAccess. Nothing else.
Before saving, check the Selected list on the right once more. The list contains high-risk policies such as AdministratorAccess, QCloudResourceFullAccess and QCloudFinanceFullAccess. Selecting a whole page by accident, or clicking the wrong row, hands out rights that have nothing to do with certificates, such as finance or administrator access.

-
Finish creating and save the SecretId and SecretKey
You can skip the tag step; confirm on the review page and create the user. The success page shows the SecretId and SecretKey, and the SecretKey is shown only once, so copy it, ready for the panel form in the next step. Afterwards, the user's API Keys tab shows only the SecretId and you can't get the SecretKey back (if you lose it, create a new key). The screenshot shows that API Keys tab when you come back to it later: only the SecretId is there.

Put the SecretKey only into the SecretKey password field in the panel (stored encrypted, shown afterwards as ******). Never paste it into chats, tickets or notes. Close the success page once you have entered it and saved the certificate.
-
Double-check the permissions
On the sub-user's Permissions tab, check that the policies list has only the one or two policies you chose.

-
Pick the script in the panel and enter the SecretId and SecretKey
In Add Certificate → Automation Scripts, set Post-issuance script to 腾讯云 SSL 证书上传与云资源更新 / Tencent Cloud SSL upload & resource update. To only upload the certificate, fill in SecretId and SecretKey (the SecretKey is a password field, stored encrypted and shown only as
******after saving) and leave every other parameter empty, including the resource types.This script only calls Tencent Cloud's API and does not touch your servers, so it needs no administrator approval.
-
Submit and validate
As before, click Next Step, then Validate in the list and confirm. When the status becomes Issued, the script runs automatically.

-
See the result in My Certificates
Open SSL Certificates → My Certificates in Tencent Cloud and you will see a new certificate: remark
nk-<domain>-<date>, source Uploaded certificate, status Issued. When it uploads again after a renewal, the same certificate doesn't show up twice.
-
Optional: swap the old certificate on cloud resources automatically
If the certificate is already bound to Tencent Cloud resources such as CDN, EdgeOne, CLB, WAF or live streaming, the script can replace it after each renewal. The parameters (all in the same script's form):
Parameter How to fill it Resource types to update Comma separated, from cdn,teo,clb,waf,live. Upload only means this and the first-deployment CDN domains are both empty. If you fill in only CDN domains, the certificate is deployed to the CDN too.CDN domains for the first deployment Used only the first time; the domains must be covered by this certificate. After that, the automatic swap takes over. Regions Needed for regional resources such as CLB and WAF, for example ap-guangzhou,ap-shanghai.Old certificate ID Optional. The ID, from My Certificates, of the certificate your resources use now; the next run moves the resources bound to it onto the new certificate. Each value is used once. It works only together with the resource types field. API endpoint For international-site accounts use ssl.intl.tencentcloudapi.com; the default is the China-site address.If you fill in resource types but there is no old certificate on record and no CDN domain, the first run logs one error asking you to bind the certificate once in the console. After that, every renewal swaps it automatically.
We have not demonstrated the resource swap on a real CDN (mainland China CDN requires a filed domain). The table above is based on the script's own documentation, so try it on an unimportant resource first.
Post-issuance script 3: deploy the certificate to another server over SSH
After every issue or renewal, the script writes the certificate and private key to another server over SSH (or, if you enter local, to a folder on this machine, for example one mounted into a container), then runs the reload command you entered. The reload command is up to you; the script never restarts anything by itself.
Because it can use root's SSH private key on this server to log in to other machines, it has one more safeguard, administrator approval: every parameter set must be checked and approved once by an administrator in the panel before the script runs, with no server login. A certificate created by an administrator is approved automatically.
-
Prepare the SSH login
If the SSH target is
local(write to this machine), skip this whole step.Otherwise, on the Nodekeeper server generate an SSH key just for this deployment; don't reuse the key root uses to log in to other machines. The script runs unattended and can't type a passphrase, so leave the passphrase empty. The private key must be owned by root with mode 600. Put the public key in a low-privilege account on the target server: it only needs to be able to write the two certificate files and run your reload command, and it should not be root on the target. Its login shell must be sh, bash, dash, zsh or similar (csh/tcsh are not supported). The commands (replace
user@hostwith the target account):ssh-keygen -t ed25519 -f /root/.ssh/nk_deploy_ed25519 -N '' ssh-copy-id -i /root/.ssh/nk_deploy_ed25519.pub user@host
-
Pick the script in the panel and fill in the parameters
Set Post-issuance script to SSH 部署证书到其它服务器 / Deploy certificate over SSH. The parameters:
Parameter What it is SSH target (required) user@host[:port]; for IPv6 writeuser@[addr]:port; enterlocalto write to this machine.SSH private key path The key file on this machine; the default is /root/.ssh/id_ed25519. Better to enter the dedicated key from the previous step,/root/.ssh/nk_deploy_ed25519.Certificate path on the target (required) An absolute path on the target; the full chain (fullchain) is written there. Private key path on the target (required) An absolute path on the target. Reload command Run on the target after writing; optional. Example: nginx -t && systemctl reload nginx.Leaf-only path / intermediate-chain-only path Optional. Fill them only if the service wants the site certificate and the intermediates stored separately. known_hosts file Optional. Left blank, the target's host key is recorded and trusted on first contact, and a later change is refused. The risk is in that first contact: if the machine you reach at that moment is an impostor, it receives the certificate and private key. So it is better to check the target's fingerprint yourself, make a known_hosts file, and enter its path here, so the check is strict every time. allow_untrusted (the last one) Default false. The script requires the certificate to validate against the system root certificates on this machine (so nobody can swap in a self-signed certificate); set it totrueonly for a self-signed or private-CA certificate. It is part of the approved parameters, so changing it needs a new approval.
-
After saving, the script waits for approval
Click Next Step, then Validate. Once the certificate is issued, this script does not run right away: it declares "approval required", so an administrator must first approve the parameter set you entered, in the panel. You will see:
- in the certificate list, a yellow Awaiting approval badge under the expiry time;
- in the certificate details (click View), the Post-issue script section says Awaiting administrator approval, and the last run reads Awaiting approval (not run).
If an administrator created this certificate, it is approved automatically when saved (the details show that administrator as the approver, with "approved by the certificate owner") and you can skip the next step.

The certificate itself was issued successfully; only the deployment script is waiting, so the certificate status stays Issued. Ordinary members also see Awaiting administrator approval, without the approve button; ask an administrator to approve.
-
The administrator approves it in the panel
An administrator with the approval permission (by default only the administrator group) opens the certificate details and clicks Approve... in the Post-issue script section. The dialog lists the whole set being approved: the script, the owner, the domains, every parameter (secret parameters shown as
******; a private key path is not a secret and is shown, so you can check which key is used) and a fingerprint. Check each item:- the SSH target, the key path and the two target paths are what you want;
- the reload command is one you recognize: it will run on the target;
- the last item,
allow_untrusted, isfalse, unless this really is a self-signed or private-CA certificate.
If everything is right, click Approve and run. If the certificate is already issued and the script has not succeeded yet, it starts in the background at once. What you approve is exactly what you saw: if anything changed after you opened the dialog, the approval is refused and the new set is shown, so review it again.
- Any change needs a new approval: the certificate, its owner, its domains, the script or any parameter. The state becomes "Changed since approval - needs approval again" and the script does not run until it is approved again.
- An administrator can click Revoke approval at any time; the script then stops running until approved again. Approving and revoking use a normal confirmation dialog and are written to the audit log.

-
Read the run details, then check the target
If the certificate is already issued and the script has not succeeded yet, approving starts it at once in the background; if it already ran, click Run now to run it again. If it fails it is retried every minute (see "Retries and where to see results" below). The Last run part of the certificate details shows the run time, the result (Succeeded / Failed / Timed out), the exit code and the end of the output, so you can read the reason without logging in to the server; Copy output copies it, and Refresh run record reloads the latest result. To run it again right away, click Run now (certificate owner and administrators; at most once per 30 seconds per certificate).
Then look at the files on the target: the certificate and the key are updated, and a newly created key file is mode 600.
How it writes: first to hidden temporary files in the same folder, then everything is renamed into place; the file being replaced is kept once as
.bak(only the previous version); a file whose content did not change is left alone; existing files keep their owner and permissions. Don't make the target folder writable by other users.
-
How to fill the parameters for common setups
The table shows typical setups. They are examples to adapt to the real paths and services on your machine; try them on an unimportant service first. We have not tested these on real Signal-TLS-Proxy and fnOS systems; for the other rows too, confirm the paths and commands on your machine before you rely on them.
Setup Certificate / key paths Reload command Another Nginx server The two files that ssl_certificateandssl_certificate_keypoint to in the Nginx confignginx -t && systemctl reload nginxAnother Apache server The two files that SSLCertificateFileandSSLCertificateKeyFilepoint toDepends on your system, for example apachectl configtest && systemctl reload apache2Proxmox VE The certificate files the PVE web interface uses; confirm the real paths on the machine first. The usual ones are /etc/pve/local/pveproxy-ssl.pemand/etc/pve/local/pveproxy-ssl.keysystemctl restart pveproxySignal-TLS-Proxy The two files the proxy actually reads its certificate and key from Whatever reloads or restarts the proxy in your setup fnOS Where the system certificate lives is not an official interface and can change between versions, so confirm the real paths on the machine first Whatever makes that system re-read the certificate A container Set the SSH target to localand use two files in the folder that is mounted into the containerYour own command to reload or restart that container (or leave it empty)
The other bundled scripts
All of these can be chosen in Add Certificate. The Slot column says which dropdown to use. Script names are given here exactly as the dropdown shows them.
| Script | Slot | What it does | What to prepare |
|---|---|---|---|
| Cloudflare DNS验证 | During issuance | Adds the DNS validation record (the example above) | A Cloudflare API token |
| DNSPod DNS验证 | During issuance | Adds the validation record through the DNSPod (Tencent Cloud DNS) API | A DNSPod API ID and Token (created on the key page at console.dnspod.cn) |
| Namecheap DNS验证 | During issuance | Adds the validation record through Namecheap's DNS API. Namecheap replaces the whole record set on every submit, so the script reads the existing records first and submits them together with the new one | Turn on API Access at Namecheap and add this server's public IP to the Namecheap whitelist. All three panel fields are required: the account user name (Namecheap账户用户名), the API key (Namecheap API密钥) and the whitelisted public IP (API白名单IP地址) |
| PowerDNS MySQL DNS验证 | During issuance | Adds the validation record through an API in front of your own PowerDNS (MySQL backend) | Deploy pdns_api.php on a web server, set its MySQL connection and a strong API key, then enter the API URL and key in the panel |
| Nginx HTTP验证 | During issuance | HTTP / HTTPS validation only: finds the server block for the right port in the Nginx config, temporarily adds the validation location, and reloads Nginx | Fill in the Service config path (the Nginx config file) when adding the certificate |
| Nginx配置清理 | Post-issuance | The partner of the one above: after issuance it removes the validation location, cleans backup files and reloads Nginx | The Nginx config file path |
| LNMP Nginx Reload | Post-issuance | Runs lnmp nginx reload so Nginx picks up the new certificate | The lnmp command must exist on the server; without it the script fails and exits |
| 百度云CDN证书更新 (Baidu Cloud CDN certificate update) | Post-issuance | Uploads the certificate to Baidu AI Cloud's certificate service and switches the given CDN domains to it. Leave the CDN domains blank to use the certificate's own domains; separate several with commas | A Baidu AI Cloud Access Key / Secret Key, from an account with CDN permission (preferably a least-privilege sub-account) |
| AWS ACM 证书导入 / AWS ACM Certificate Import 腾讯云 SSL 证书上传与云资源更新 / Tencent Cloud SSL upload & resource update SSH 部署证书到其它服务器 / Deploy certificate over SSH | Post-issuance | The three detailed examples in this guide | See above |
For the DNSPod, Namecheap and PowerDNS scripts, the keys are entered in the panel parameters and handed to the script as command-line arguments (ordinary inputs), so use an account with least privilege for them. The Baidu Cloud CDN Secret Key is a password field like the AWS and Tencent Cloud ones: it goes through the environment, never on the command line; only its Access Key ID is a command-line argument.
Retries and where to see results
Failures are retried by themselves. If a post-issuance script fails (say the cloud account lacks a permission, or the network is down), Nodekeeper runs it again at the next minute's check, until it succeeds. (For the Tencent Cloud script, an error that will not fix itself, such as missing permission or rejected parameters, is retried with a growing delay, up to 1 hour, and Tencent Cloud is not called again in between; changing the parameters or the certificate retries at once.) A script that needs approval and takes longer than 15 minutes is terminated and recorded as Timed out (older scripts without the approval line have no such limit). A script that needs approval does not run at all before it is approved. In our testing AWS failed once because the import permission was missing; after the policy was fixed we did nothing else and the script succeeded on its own.
Where to look.
- In the panel (first choice): click View to open the certificate details and look at the Post-issue script section. Last run has the time, the result (Succeeded / Failed / Timed out / Awaiting approval), the exit code and the last ~4 KiB of the output (keys masked); the certificate owner and administrators can see it, and there are Copy output and Refresh run record buttons. In the certificate list, a certificate whose script failed has a red Script failed badge under the expiry time, and one waiting for approval has a yellow Awaiting approval badge.
- Log: the log under
logs/in the Nodekeeper install directory has more complete records. - Success: check the target itself, for example whether the certificate is in ACM or in Tencent Cloud's My Certificates, or whether the certificate files on the target server are updated.
Something wrong? Check this table
| What you see | Why | What to do |
|---|---|---|
| A red Script failed badge under the certificate in the list | The post-issuance script's last run failed. | Click View and read the end of the output in Last run under Post-issue script; fix the cause. The script retries every minute, so nothing else is needed once it is fixed. |
| The AWS script fails and the output says permission is missing | The IAM user lacks the import permission. | Add the inline policy as in the AWS section above; the script succeeds by itself on the next retry. |
| The Tencent Cloud script waits a long time before retrying | For errors that won't fix themselves (missing permission, rejected parameter) the retry interval grows, up to 1 hour. | It retries at once after you fix the permission or parameters. |
| A yellow Awaiting approval badge and the script never runs | The script needs an administrator's approval and does not run before it. | Ask an administrator to open the details and click Approve... |
| The result is Timed out | A script that needs approval ran for more than 15 minutes and was stopped. | See where the output stops; check the target server's network and the reload command. |
Write your own: SSL script development guide
Need to send certificates somewhere the bundled scripts don't cover (FTP upload, an SMB share, your own release tool), or validate with a DNS provider the panel doesn't support? See the SSL Script Development Guide: where scripts live, the header, the arguments a script receives, passing keys safely, exit codes and retries, which scripts need approval, and complete examples for a post-issuance script (FTPS upload) and an issuing script (DNS validation).
Frequently asked questions
- Do certificates renew automatically without scripts?
- Yes. Certificates with HTTP validation, or with Built-in DNS validation on, renew by themselves. Scripts solve two other problems: adding DNS records when your DNS is at Cloudflare or similar, and sending the certificate elsewhere.
- Can other people see the keys I enter?
- The AWS, Tencent Cloud and Baidu Cloud CDN secret keys are password fields: stored encrypted, shown as
******in the panel and the audit log, and passed to the script through the environment. DNSPod, Namecheap and PowerDNS keys are ordinary fields passed as command-line arguments; give them least-privilege accounts. - Why does SSH deploy need approval and AWS not?
- SSH deploy logs in to another machine and runs commands from its parameters; the script runs as root, so without approval whoever fills the parameters would control it. AWS and Tencent Cloud scripts only call cloud APIs with the key you enter and can't touch your machines.
- If a post-issuance script fails, can I still use the certificate?
- Yes. The certificate in Nodekeeper is issued and in use; the script retries every minute, and until it succeeds the target (cloud service, other server) keeps the old certificate.
- Can one certificate be deployed to several places?
- Each certificate has one post-issuance script. To deploy to several places, write a script that does all the steps; see the SSL Script Development Guide.
- Can I add a script to an existing certificate?
- The script is chosen in Add Certificate; an existing certificate cannot be changed. Add another certificate for the domain with the script selected.
