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

ACME client support for standalone and webroot mode #122

Merged
merged 1 commit into from
Sep 13, 2019

Conversation

dopey
Copy link
Contributor

@dopey dopey commented Jul 30, 2019

Integrate with any ACME 2.0 server to get certificates using standalone or webroot mode.

@dopey dopey requested a review from maraino July 30, 2019 17:52
@codecov
Copy link

codecov bot commented Jul 30, 2019

Codecov Report

Merging #122 into master will increase coverage by 0.63%.
The diff coverage is 16.66%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #122      +/-   ##
==========================================
+ Coverage   68.37%   69.01%   +0.63%     
==========================================
  Files          61       61              
  Lines        8349     8292      -57     
==========================================
+ Hits         5709     5723      +14     
+ Misses       2271     2201      -70     
+ Partials      369      368       -1
Impacted Files Coverage Δ
errs/errs.go 6.61% <0%> (+0.21%) ⬆️
command/certificate/sign.go 47.94% <100%> (-0.71%) ⬇️
crypto/x509util/crt.go 6.25% <0%> (-23.17%) ⬇️
crypto/keys/key.go 69.13% <0%> (ø) ⬆️
command/certificate/verify.go 51.35% <0%> (ø) ⬆️
token/token.go 100% <0%> (ø) ⬆️
crypto/x509util/profile.go 0% <0%> (ø) ⬆️
command/certificate/create.go 54.57% <0%> (+5.75%) ⬆️
token/options.go 94.11% <0%> (+9.9%) ⬆️
... and 1 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e097873...1868ec3. Read the comment docs.

command/ca/certificate.go Outdated Show resolved Hide resolved
command/ca/certificate.go Outdated Show resolved Hide resolved
command/ca/certificate.go Show resolved Hide resolved
command/ca/certificate.go Outdated Show resolved Hide resolved
@@ -443,3 +486,408 @@ func parseTimeDuration(ctx *cli.Context) (notBefore api.TimeDuration, notAfter a
}
return
}

Copy link
Collaborator

Choose a reason for hiding this comment

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

Move everything after this to a new file.

Copy link
Collaborator

Choose a reason for hiding this comment

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

It might be even wiser to create a package with this functionality.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

For the time being I've moved everything acme related into one file under the command/ca package. Not sure about the benefit of creating a new package. Maybe that will become more clear when we need to add more functionality.

command/ca/certificate.go Outdated Show resolved Hide resolved
command/ca/certificate.go Outdated Show resolved Hide resolved
errs/errs.go Outdated Show resolved Hide resolved
command/ca/certificate.go Outdated Show resolved Hide resolved
command/ca/certificate.go Outdated Show resolved Hide resolved
@dopey dopey force-pushed the max/acme-standalone branch 2 times, most recently from 9f11571 to 56d1c6d Compare August 12, 2019 18:11
@dopey dopey requested a review from maraino August 14, 2019 21:49
Copy link
Collaborator

@maraino maraino left a comment

Choose a reason for hiding this comment

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

I've added a few comments.

command/ca/acmeutils.go Outdated Show resolved Hide resolved
command/ca/acmeutils.go Outdated Show resolved Hide resolved
command/ca/certificate.go Outdated Show resolved Hide resolved
command/ca/certificate.go Outdated Show resolved Hide resolved
command/ca/certificate.go Outdated Show resolved Hide resolved
command/ca/certificate.go Outdated Show resolved Hide resolved
@@ -490,6 +500,8 @@ func provisionerPrompt(ctx *cli.Context, provisioners provisioner.List) (provisi
return true
case provisioner.TypeGCP, provisioner.TypeAWS, provisioner.TypeAzure:
return true
case provisioner.TypeACME:
return ctx.Command.Name == "certificate"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Do we want to support step provisioner sign?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

assuming you mean step ca sign

@dopey dopey force-pushed the max/acme-standalone branch 3 times, most recently from 396a0be to d44aad4 Compare September 13, 2019 22:51
@dopey dopey merged commit 7e4724b into master Sep 13, 2019
@dopey dopey deleted the max/acme-standalone branch September 13, 2019 22:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants