I am trying to configure Anycable in a Rails 5.2 application which needs to communicate with a GO server.
This is my anycable configuration in the Rails:
default: &default
rpc_host: "localhost:50051"
log_grpc: false
log_file: nil
debug: false # Shortcut to enable GRPC logging and debug level
log_level: info
redis_channel: "__anycable__"
redis_sentinels: []
production:
<<: *default
redis_url: "redis://localhost:6379/1"
development:
<<: *default
redis_url: "redis://localhost:6379/2"
And the anycable server runs in localhost:3334 (Using default settings.) However when I try to connect to the same server from the GO application I am starting to get connection timeout errors from the Rails side. (Tried vice versa and got timeout on the GO side)
I have my next file:
config/anycable.yml
development:
# gRPC server host
rpc_host: "localhost:50051"
# Redis URL (for broadcasting)
redis_url: "redis://localhost:6379/2"
# You can also turn on access logging
access_logs_disabled: false
debug: true
and I run my servers:
my file Procfile.dev is not neccessary
web: bundle exec rails s -b 0.0.0.0 -p 3000
rpc: bundle exec ./bin/anycable
go: sleep 5 && ./cable/anycable-go-0.5.4 -addr 'host.lvh.me:8080' -disconnect_rate=1