Alias via domains.txt broken? #582

Closed
opened 2025-12-29 01:27:30 +01:00 by adam · 1 comment
Owner

Originally created by @Lem on GitHub (Sep 22, 2022).

I tried to get a wildcard-only certificate for *.example.com via domains.txt. But it was not recognized by the script.

According to the documentation you can add the line *.example.com > star_example_com, but using the command ./dehydrated -d '*.example.com' -c results in an error.

Using the command line argument (./dehydrated -d '*.example.com' -c --alias star_example_com) works fine.

Adding some debug lines I found out that the function parse_domains_txt seems to produce an output containing the '>', but it is missing in the variable line of the the for-loop responsible for the alias-logic (https://github.com/dehydrated-io/dehydrated/blob/master/dehydrated#L1656).

Output of both commands:

 [bla@host dehydrated]$ ./dehydrated -d '*.example.com' -c 
# INFO: Using main config file /tmp/dehydrated/config
Processing *.example.com
ERROR: Please define a valid alias for your *.example.com wildcard-certificate. See domains.txt-documentation for more details.

[bla@host dehydrated]$ ./dehydrated -d '*.example.com' -c  --alias star_example_com
# INFO: Using main config file /tmp/dehydrated/config
Processing *.example.com
 + Creating new directory /tmp/dehydrated/certs/star_example_com ...
 + Signing domains...
[...]
Originally created by @Lem on GitHub (Sep 22, 2022). I tried to get a wildcard-only certificate for `*.example.com` via `domains.txt`. But it was not recognized by the script. According to the documentation you can add the line `*.example.com > star_example_com`, but using the command `./dehydrated -d '*.example.com' -c` results in an error. Using the command line argument (`./dehydrated -d '*.example.com' -c --alias star_example_com`) works fine. Adding some debug lines I found out that the function `parse_domains_txt` seems to produce an output containing the '>', but it is missing in the variable `line` of the the for-loop responsible for the alias-logic (https://github.com/dehydrated-io/dehydrated/blob/master/dehydrated#L1656). Output of both commands: ```bash [bla@host dehydrated]$ ./dehydrated -d '*.example.com' -c # INFO: Using main config file /tmp/dehydrated/config Processing *.example.com ERROR: Please define a valid alias for your *.example.com wildcard-certificate. See domains.txt-documentation for more details. [bla@host dehydrated]$ ./dehydrated -d '*.example.com' -c --alias star_example_com # INFO: Using main config file /tmp/dehydrated/config Processing *.example.com + Creating new directory /tmp/dehydrated/certs/star_example_com ... + Signing domains... [...] ```
adam closed this issue 2025-12-29 01:27:30 +01:00
Author
Owner

@lukas2511 commented on GitHub (Sep 22, 2022):

That is intended behaviour. When you define domains via the cli arguments the domains.txt file gets ignored completely.

@lukas2511 commented on GitHub (Sep 22, 2022): That is intended behaviour. When you define domains via the cli arguments the `domains.txt` file gets ignored completely.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/dehydrated#582