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

cmd: replace newline in HTTP_TLS #331

Merged
merged 1 commit into from
Dec 19, 2016
Merged

Conversation

ewilde
Copy link
Contributor

@ewilde ewilde commented Dec 19, 2016

HTTPS_TLS_CERT and HTTPS_TLS_KEY environment variables can contain \n
see:https://github.com/ory-am/hydra/blob/master/cmd/host.go
This commit replaces the \n characters with an actual newline to allow
the tls package to correctly create a X509 key pair.

Otherwise the X509 key pair fails to get created.

Signed-off-by: Edward Wilde ewilde@gmail.com

HTTPS_TLS_CERT and HTTPS_TLS_KEY environment variables can contain \n
see:https://github.com/ory-am/hydra/blob/master/cmd/host.go
This commit replaces the \n character with an actual newline to allow
the tls package to correctly create a X509 key pair.

Signed-off-by: Edward Wilde <ewilde@gmail.com>
@aeneasr
Copy link
Member

aeneasr commented Dec 19, 2016

Does this work on windows / linux / osx alike?

@aeneasr
Copy link
Member

aeneasr commented Dec 19, 2016

Because windows has \r\n right?

@ewilde
Copy link
Contributor Author

ewilde commented Dec 19, 2016

I will test it on windows and get back to you. I've only tried it on mac and linux

@ewilde
Copy link
Contributor Author

ewilde commented Dec 19, 2016

Seems to load okay on window

image

See 'Loaded certificate from environment variable' at the bottom

@aeneasr
Copy link
Member

aeneasr commented Dec 19, 2016

Cool, thanks for investigating!

@aeneasr aeneasr merged commit 5a4a2e8 into ory:master Dec 19, 2016
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