Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
Cryptocoryne
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
LOFAR2.0
Cryptocoryne
Commits
5c3323a3
Commit
5c3323a3
authored
6 months ago
by
Hannes Feldt
Browse files
Options
Downloads
Patches
Plain Diff
L2SS-2063
: Add certificate documentation
parent
fef103f9
No related branches found
No related tags found
2 merge requests
!3
L2SS-2063: Add certificate documentation
,
!2
L2SS-2063: Add certificate documentation
Pipeline
#101163
passed with warnings
6 months ago
Stage: prepare
Stage: lint
Stage: test
Stage: package
Stage: images
Stage: integration
Pipeline: Cryptocoryne
#101164
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
README.md
+30
-9
30 additions, 9 deletions
README.md
with
30 additions
and
9 deletions
README.md
+
30
−
9
View file @
5c3323a3
#
Cryptocoryne
#
Stingray




<!--  -->
An example repository of an CI/CD pipeline for building, testing and publishing a python package
.
Cryptocoryne registeres and renews certificates for the lofar.net domain based on consul service registrations
.
## Installation
```
pip install .
```
## Usage
```
python
from
lofar
-
cryptocoryne
import
cool_module
cool_module
.
greeter
()
# prints "Hello World"
Cryptocoryne runs periodically on the central nomad cluster.
Every 5 minutes, cryptocoryne queries all services registered within consul that have the tag
`cert`
.
Then the certificate
`<service_name>.lofar.net`
is registered or renewed (if needed) and stored in the LOFAR vault.
Services then have the option to retrieve the certificates from the vault using nomads job templating:
```
hcl
template
{
data
=
<<
EOH
{{
with
secret
"lets-encrypt/certificates/<service_name>.lofar.net"
-
}}
{{.
Data
.
data
.
cert
}}
{{.
Data
.
data
.
chain
-
}}
{{
end
}}
EOH
destination
=
"${NOMAD_SECRETS_DIR}/fullchain.cer"
}
template
{
data
=
<<
EOH
{{
with
secret
"lets-encrypt/certificates/<service_name>.lofar.net"
-
}}
{{.
Data
.
data
.
key
-
}}
{{
end
}}
EOH
destination
=
"${NOMAD_SECRETS_DIR}/key.key"
}
```
## Contributing
To contribute, please create a feature branch and a "Draft" merge request.
...
...
@@ -29,7 +50,7 @@ changes is done through `tox`.
```
pip install tox```
With tox the same jobs as run on the CI/CD pipeline can be r
a
n. These
With tox the same jobs as run on the CI/CD pipeline can be r
u
n. These
include unit tests and linting.
```
tox
```
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment