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

Using rediss (ssl wrapped redis) as storage_adapter #191

Closed
TrurlMcByte opened this issue Sep 17, 2019 · 4 comments
Closed

Using rediss (ssl wrapped redis) as storage_adapter #191

TrurlMcByte opened this issue Sep 17, 2019 · 4 comments
Milestone

Comments

@TrurlMcByte
Copy link

Any solution (excluding stunnel-like) for using rediss protocol (redis over ssl)?

@TrurlMcByte
Copy link
Author

resty.redis have options_table optional argument, where possible to enable ssl
https://github.com/openresty/lua-resty-redis#connect
But this argument not used in
https://github.com/GUI/lua-resty-auto-ssl/blob/master/lib/resty/auto-ssl/storage_adapters/redis.lua#L39

@gjongenelen
Copy link
Contributor

As far as I can see, making the following change would allow you to pass additional options to redis:connect
gjongenelen@ad94e4d

@TrurlMcByte
Copy link
Author

@gjongenelen Manually I did solution like this already, but it's "one-time-solutions", and next version may be incompatible with this changes.

@GUI GUI added this to the v0.13.0 milestone Sep 30, 2019
@GUI
Copy link
Collaborator

GUI commented Sep 30, 2019

In the new v0.13.0 release of lua-resty-auto-ssl, there's now support for passing connect_options to the redis configuration, which allows for configuring any of these connect options: https://github.com/GUI/lua-resty-auto-ssl#redis So this should be possible through something like:

auto_ssl:set("redis", {
  host = "10.10.10.1",
  connect_options = {
    ssl = true,
    ssl_verify = true,
  },
})

However, note that these SSL options only recently landed in lua-resty-redis's master (openresty/lua-resty-redis#168), so these SSL specific options are not currently part of an official lua-resty-redis or OpenResty release. It should be part of lua-resty-redis's next release, but in the meantime, you'd need to install that module from master if you're looking to take advantage of this.

@GUI GUI closed this as completed Sep 30, 2019
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

3 participants