Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add DNS Provider for IIJ DNS Platform Service #1646

Merged
merged 6 commits into from
May 20, 2022

Conversation

mimuret
Copy link
Contributor

@mimuret mimuret commented May 19, 2022

Add DNS Provider for IIJ DNS Platform Service

Fixes #1644

(re-create from #1645)


manabu-s@manabu-s lego % dist/lego -m [email protected] --dns iijdpf -d '*.iijtest-2017061600.org' -d iijtest-2017061600.org -s https://acme-staging-v02.api.letsencrypt.org/directory run
2022/05/19 00:10:38 [INFO] [*.iijtest-2017061600.org, iijtest-2017061600.org] acme: Obtaining bundled SAN certificate
2022/05/19 00:10:38 [INFO] [*.iijtest-2017061600.org] AuthURL: https://acme-staging-v02.api.letsencrypt.org/acme/authz-v3/2477748104
2022/05/19 00:10:38 [INFO] [iijtest-2017061600.org] AuthURL: https://acme-staging-v02.api.letsencrypt.org/acme/authz-v3/2477748114
2022/05/19 00:10:38 [INFO] [*.iijtest-2017061600.org] acme: use dns-01 solver
2022/05/19 00:10:38 [INFO] [iijtest-2017061600.org] acme: Could not find solver for: tls-alpn-01
2022/05/19 00:10:38 [INFO] [iijtest-2017061600.org] acme: Could not find solver for: http-01
2022/05/19 00:10:38 [INFO] [iijtest-2017061600.org] acme: use dns-01 solver
2022/05/19 00:10:38 [INFO] [*.iijtest-2017061600.org] acme: Preparing to solve DNS-01
2022/05/19 00:10:51 [INFO] [iijtest-2017061600.org] acme: Preparing to solve DNS-01
2022/05/19 00:11:03 [INFO] [*.iijtest-2017061600.org] acme: Trying to solve DNS-01
2022/05/19 00:11:03 [INFO] [*.iijtest-2017061600.org] acme: Checking DNS record propagation using [1.1.1.1:53]
2022/05/19 00:11:08 [INFO] Wait for propagation [timeout: 11m0s, interval: 5s]
2022/05/19 00:11:23 [INFO] [*.iijtest-2017061600.org] The server validated our request
2022/05/19 00:11:23 [INFO] [iijtest-2017061600.org] acme: Trying to solve DNS-01
2022/05/19 00:11:23 [INFO] [iijtest-2017061600.org] acme: Checking DNS record propagation using [1.1.1.1:53]
2022/05/19 00:11:28 [INFO] Wait for propagation [timeout: 11m0s, interval: 5s]
2022/05/19 00:11:45 [INFO] [iijtest-2017061600.org] The server validated our request
2022/05/19 00:11:45 [INFO] [*.iijtest-2017061600.org] acme: Cleaning DNS-01 challenge
2022/05/19 00:11:57 [INFO] [iijtest-2017061600.org] acme: Cleaning DNS-01 challenge
2022/05/19 00:12:08 [INFO] [*.iijtest-2017061600.org, iijtest-2017061600.org] acme: Validations succeeded; requesting certificates
2022/05/19 00:12:09 [INFO] [*.iijtest-2017061600.org] Server responded with a certificate.

@ldez
Copy link
Member

ldez commented May 19, 2022

Hello, in order for a PR adding a DNS provider to be accepted, you have to:

  • add a description to your PR
  • be able to maintain this provider
  • have a homogeneous design with the other providers
  • add tests (units)
make test
  • add tests ("live")
    func TestLivePresent(t *testing.T) {
    if !envTest.IsLiveTest() {
    t.Skip("skipping live test")
    }
    envTest.RestoreEnv()
    provider, err := NewDNSProvider()
    require.NoError(t, err)
    err = provider.Present(envTest.GetDomain(), "", "123d==")
    require.NoError(t, err)
    }
    func TestLiveCleanUp(t *testing.T) {
    if !envTest.IsLiveTest() {
    t.Skip("skipping live test")
    }
    envTest.RestoreEnv()
    provider, err := NewDNSProvider()
    require.NoError(t, err)
    time.Sleep(2 * time.Second)
    err = provider.CleanUp(envTest.GetDomain(), "", "123d==")
    require.NoError(t, err)
    }
make test
make generate-dns
  • be able to do: (and put the output of this command to a comment in your PR)
rm -rf .lego

./lego -m [email protected] --dns YOUR_PROVIDER_NAME -d *.example.com -d example.com -s https://acme-staging-v02.api.letsencrypt.org/directory run

Note the wildcard domain is important.

make checks
  • do go mod tidy

@ldez ldez added this to the v4.7 milestone May 19, 2022
Copy link
Member

@ldez ldez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks 👍

@ldez ldez enabled auto-merge (squash) May 20, 2022 19:47
@ldez ldez force-pushed the add-dns-provider-iijdpf branch from 352203d to 52a9f9b Compare May 20, 2022 20:16
@ldez ldez merged commit 81f1fab into go-acme:master May 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

Support for provider: IIJ DNS Platform Service (iijdpf)
2 participants