graylog-labs / graylog2-puppet

[DEPRECATED] Puppet module to install and manage a Graylog 1.x system.
https://www.graylog.org/
MIT License
10 stars 28 forks source link

changed rest/server URIs make problems #6

Closed syss closed 10 years ago

syss commented 10 years ago

When I configure graylog2 server with most default values it works.

class {'graylog2::repo':
                version => '0.21',
        } ->
        class {'graylog2::server':
                service_enable => 'true',
                elasticsearch_cluster_name => 'elasticsearch',
                password_secret         => 'value',
                root_password_sha2      => 'value',
        } ->
        class {'graylog2::web':
                application_secret      => 'value',
        }

However I encounter a problem when trying to send email alerts it does not work, despite the fact it states all looks good.

I found out that the problem with the email alerts can be solved to change the IPs in the graylog2.conf to the network IP (rather than 127.0.0.1).

But if one changes the IP in the puppetmodule like the following, the graylog-web interface can't find the graylog-server anymore.

class {'graylog2::repo':
                version => '0.21',
        } ->
        class {'graylog2::server':
                service_enable => 'true',
                elasticsearch_cluster_name => 'elasticsearch',
                rest_listen_uri => "http://${::ipaddress}:12900",
                rest_transport_uri => "http://${::ipaddress}:12900",
                password_secret         => 'value',
                root_password_sha2      => 'value',
        } ->
        class {'graylog2::web':
                application_secret      => 'value',
                graylog2_server_uris           => ["http://${::ipaddress}:12900"],
        }

are there any suggestions to work around this issue?

bernd commented 10 years ago

Thanks for the report, I will look into this.

syss commented 10 years ago

I just found out that it had problems without the trailing slash for the URI. Maybe a little note would save some trial and error time for some users. Nevertheless if you want to send alert emails in graylog you need to set the IP to a nonlocal or as stated in the config to 0.0.0.0 which would be the first non loopback address.