项目作者: slicen

项目描述 :
Cert-Manager ACME DNS01 Webhook Solver for Linode DNS Manager
高级语言: Go
项目地址: git://github.com/slicen/cert-manager-webhook-linode.git
创建时间: 2020-06-23T03:47:37Z
项目社区:https://github.com/slicen/cert-manager-webhook-linode

开源协议:Apache License 2.0

下载


Cert-Manager ACME DNS01 Webhook Solver for Linode DNS Manager

Go Report Card
Releases
LICENSE

A webhook to use Linode DNS
Manager
as a DNS01
ACME Issuer for cert-manager.

Installation

  1. helm install cert-manager-webhook-linode \
  2. --namespace cert-manager \
  3. https://github.com/slicen/cert-manager-webhook-linode/releases/download/v0.2.0/cert-manager-webhook-linode-v0.2.0.tgz

Usage

Create Linode API Token Secret

  1. kubectl create secret generic linode-credentials \
  2. --namespace=cert-manager \
  3. --from-literal=token=<LINODE TOKEN>

Create Issuer

Cluster-wide Linode API Token

  1. apiVersion: cert-manager.io/v1
  2. kind: ClusterIssuer
  3. metadata:
  4. name: letsencrypt-staging
  5. spec:
  6. acme:
  7. server: https://acme-staging-v02.api.letsencrypt.org/directory
  8. email: example@example.com
  9. privateKeySecretRef:
  10. name: letsencrypt-staging
  11. solvers:
  12. - dns01:
  13. webhook:
  14. solverName: linode
  15. groupName: acme.slicen.me

By default, the Linode API token used will be obtained from the
linode-credentials Secret in the same namespace as the webhook.

Per Namespace Linode API Tokens

If you would prefer to use separate Linode API tokens for each namespace (e.g.
in a multi-tenant environment):

  1. apiVersion: cert-manager.io/v1
  2. kind: Issuer
  3. metadata:
  4. name: letsencrypt-staging
  5. namespace: default
  6. spec:
  7. acme:
  8. server: https://acme-staging-v02.api.letsencrypt.org/directory
  9. email: example@example.com
  10. privateKeySecretRef:
  11. name: letsencrypt-staging
  12. solvers:
  13. - dns01:
  14. webhook:
  15. solverName: linode
  16. groupName: acme.slicen.me
  17. config:
  18. apiKeySecretRef:
  19. name: linode-credentials
  20. key: token

Development

Running the test suite

Conformance testing is achieved through Kubernetes emulation via the
kubebuilder-tools suite, in conjunction with real calls to the Linode API on an
test domain, using a valid API token.

The test configures a cert-manager-dns01-tests TXT entry, attempts to verify its
presence, and removes the entry, thereby verifying the Prepare and CleanUp
functions.

Run the test suite with:

  1. ./scripts/fetch-test-binaries.sh
  2. export LINODE_TOKEN=$(echo -n "<your API token>" | base64 -w 0)
  3. envsubst < testdata/linode/secret.yaml.example > testdata/linode/secret.yaml
  4. TEST_ZONE_NAME=yourdomain.com. make verify