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

setting up raxx for ssl #30

Closed
CharlesOkwuagwu opened this issue Feb 22, 2017 · 13 comments
Closed

setting up raxx for ssl #30

CharlesOkwuagwu opened this issue Feb 22, 2017 · 13 comments

Comments

@CharlesOkwuagwu
Copy link
Contributor

Thanks for this simple web server library.

Please can you give an example of how to setup raxx as a secure server, i.e. with ssl.
I have looked at your Elli and Cowboy adaptors, I cannot find where you handle https.

@CrowdHailer
Copy link
Owner

Hi,

I have not done this yet. It is on my too do list but I am working on supporting HTTP/2 as well. Still at the stage of proving that the raxx interface can handle all the usecases I need it for. After that the top priority is probably ssl.

I don't know your level but if you fancy tackling this yourself I am very happy to give you any clarification about the code that does exist

@CharlesOkwuagwu
Copy link
Contributor Author

Thanks for the quick response.

I'll take a closer look at how you enabled http: and tcp: for cowboy, then compare against Plug's cowboy adapter implementation for https:

If I make any headway, i'll send a PR

@CrowdHailer
Copy link
Owner

Awesome. You are the first person to show up interested 👍

I hope the cowboy adapter is up to date. I have been making most recent changes against the Ace Adapter. If you have any trouble setting up just HTTP with the cowboy adapter let me know because that should be a quick fix.

@CharlesOkwuagwu
Copy link
Contributor Author

CharlesOkwuagwu commented Feb 23, 2017

Nope, no luck setting up the cowboy example with the current version of cowboy: 1.1.2

The Elli setup on the other hand was really easy out of the box

@CrowdHailer
Copy link
Owner

Alright will check that out this evening.

@CharlesOkwuagwu
Copy link
Contributor Author

https://github.com/CrowdHailer/raxx/blob/master/raxx_elli/lib/raxx/elli/handler.ex#L36

This can no longer be hardcoded as "http"

I am unable to find out how to pull the scheme off the elli_request

@CrowdHailer
Copy link
Owner

@CharlesOkwuagwu just pushed a patch version of :raxx_cowboy that uses the latest version of raxx and cowboy. Small tweets to the example and it now appears to be working

https://github.com/CrowdHailer/raxx/blob/master/example/cowboy_example/lib/cowboy_example.ex

Glad the elli adapter was easy. I think that better README's for the adapters are probably the most useful piece of documentation for me to get started on

@CharlesOkwuagwu
Copy link
Contributor Author

I have Elli working with SSL :)

See this gist: https://gist.github.com/CharlesOkwuagwu/1eedf9eb5e3a212b51b658be78e6abf3

@CharlesOkwuagwu
Copy link
Contributor Author

Also for consistency, can you make the cowboy example Supervised like the elli example.

mix new raxx_cowboy_demo --sup

Unable to modify it to be properly supervised.

@CrowdHailer
Copy link
Owner

Thanks for the gist that is great. If you want to create a whole project in the examples directory called elli_ssh or something that would be cool. That examples directory is a bit of a grab bag at the moment but it can be cleaned up later on

@CrowdHailer
Copy link
Owner

switching cowboy adapter so it can be used under a supervision tree. #31
includes some notes about how it might be done

@CrowdHailer
Copy link
Owner

CrowdHailer commented Feb 26, 2017

Hi @CharlesOkwuagwu Does the release of raxx_cowboy 0.2.0 Handle your reason for opening this issue? If so I can close it.

I have also opened a new issue for documentation issue for setting up raxx and cowboy #34

@CharlesOkwuagwu
Copy link
Contributor Author

yes we can close this. The changes we made in 0.2.0 seem adequate for now.

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

No branches or pull requests

2 participants