Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
certman
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
IML Open Source
certman
Merge requests
!24
Add http challenge
Code
Review changes
Check out branch
Download
Patches
Plain diff
Expand sidebar
Merged
Add http challenge
add-http-challenge
into
master
Overview
0
Commits
2
Pipelines
0
Changes
2
Merged
Add http challenge
Hahn Axel (hahn)
requested to merge
add-http-challenge
into
master
7 months ago
Overview
0
Commits
2
Pipelines
0
Changes
2
0
0
Merge request reports
Viewing commit
8d0b76f4
Prev
Next
Show latest version
2 files
+
193
−
105
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
2
8d0b76f4
update docs
· 8d0b76f4
Hahn Axel (hahn)
authored
7 months ago
docs/30_Usage.md
+
78
−
59
View file @ 8d0b76f4
Edit in single-file editor
Open in Web IDE
Show full file
@@ -6,94 +6,113 @@ Verify a new setup (or changes in the config) with `./cm.sh selftest`.
## Show help
Without
any parameter
it shows a help.
Without
-h or --help
it shows a help.
```
text
./cm.sh
./cm.sh
-h
_______________________________________________________________________________
- - - ---===>>> CERT MANAGER <<<===--- - - -
- - - ---===>>> CERT MANAGER
- v2025-01-08
<<<===--- - - -
_______________________________________________________________________________
DEBUG: Using Let's Encrypt STAGE environment ...
DEBUG: You can test and mess around. Do not use certs in production.
HELP
The basic syntax is
cm.sh [--trace] ACTION [FQDN] [ALIAS_1 [.. ALIAS_N]]
Wrapper script for acme.sh to handle certificates.
For automation you should use the "ensure" action that detects if a
certificate must be created, renewed or re-created.
The ACTIONs for SINGLE certificate handlings are:
📄 Source: <https://git-repo.iml.unibe.ch/iml-open-source/iml-certman>
📜 License: GNU GPL 3.0
📗 Docs: <https://os-docs.iml.unibe.ch/iml-certman/>
add FQDN [.. FQDN-N]
create new certificate
The first FQDN is a hostname to generate the certificate for.
Following multiple hostnames will be used as DNS aliases in the
same certificate.
It updates files in ./certs
SYNTAX:
ensure FQDN [.. FQDN-N]
It ensures that a certificate with given aliases exists and is up to date.
This param is for simple usage in automation tools like Ansible or Puppet.
It is required to add all aliases as parameters what is unhandy for
direct usage on cli.
dev_cm.sh [OPTIONS] ACTION <FQDN> [<ALIASES>]
If the cert does not exist it will be created (see "add").
If fqdn and aliases are the same like in the certificate it performs a renew.
If fqdn and aliases differ:
- the current certificate will be rejected + deleted (see "delete")
- a new certificate will be added ()
OPTIONS:
delete FQDN
delete all files of a given certificate
-a|--alias
Use http challenge with existing http server on port 80
Challenge file will be written into ../alias-dir/
renew FQDN
renew (an already added) certificate
and update files in ./certs
-f|--force
Force renew of certificate even if it is not due yet.
Use it carefully - remember the execution limits on Let's Encrypt.
show FQDN
show place of certificate data and show basic certificate data
(issuer, subject, aliases, ending date)
-t|--trace
the output additionally will be written into a tracelog file
below ./log.
transfer FQDN
Transfer cert from acme.sh internal cache to our output dir again
.
It is done during add or renew. With transfer command you can repeat it.
-v|--verbose
show debug infos on console
.
Remark: for permanent usage set CM_showdebug=1 in inc_config.sh
ACTIONs for ALL certs
-w|--webroot <DIR>
Use http challenge with existing http server on port 80
Challenge file will be written into given directory
list
list all certificates including creation and renew date
The ACTIONs for SINGLE certificate handlings are:
list-old
list all certificates older 65 and older 90 days and exit.
Exitcodes:
0 - all certs are up to date.
1 - certificates to renew were found
2 - outdatedt certificates were found
add <FQDN> [.. <FQDN-N>]
create new certificate
The first FQDN is a hostname to generate the certificate for.
Following multiple hostnames will be used as DNS aliases in the
same certificate.
It updates files in
renew-all
renew all certificates (fast mode - without --force)
and update files in ./certs
It is useful for a cronjob.
ensure <FQDN> [.. <FQDN-N>]
It ensures that a certificate with given aliases exists and is up to date.
This param is for simple usage in automation tools like Ansible or Puppet.
It is required to add all aliases as parameters what is unhandy for
direct usage on cli.
other ACTIONs
If the cert does not exist it will be created (see "add").
If fqdn and aliases are the same like in the certificate it performs a renew.
If fqdn and aliases differ:
- the current certificate will be rejected + deleted (see "delete")
- a new certificate will be added ()
delete <FQDN>
delete all files of a given certificate
renew <FQDN>
renew (an already added) certificate
and update files in
selftest
check of health with current setup and requirements.
This command is helpful for initial setups.
show <FQDN>
show place of certificate data and show basic certificate data
(issuer, subject, aliases, ending date)
OPTIONS
--trace (it must be the 1st parameter)
the output additionally will be written into a tracelog file
below ./log.
transfer <FQDN>
Transfer cert from acme.sh internal cache to our output dir again.
It is done during add or renew. With transfer command you can repeat it.
ACTIONs for ALL certs
list
list all certificates including creation and renew date
list-old
list all certificates older 65 and older 90 days and exit.
Exitcodes:
0 - all certs are up to date.
1 - certificates to renew were found
2 - outdatedt certificates were found
renew-all
renew all certificates (fast mode - without --force)
and update files in
It is useful for a cronjob.
other ACTIONs
DEBUG: Using Let's Encrypt STAGE environment ...
DEBUG: You can test and mess around. Do not use certs in production.
selftest
check of health with current setup and requirements.
This command is helpful for initial setups.
```
Loading