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

Support for http auth method #203

Open
Goutam192002 opened this issue Feb 4, 2021 · 1 comment
Open

Support for http auth method #203

Goutam192002 opened this issue Feb 4, 2021 · 1 comment

Comments

@Goutam192002
Copy link

ejabberd_auth_http method enables http authentication for ejabberd. I have added this module to my variable as follows:

EJABBERD_CONTRIB_MODULES=ejabberd_auth_http

This works fine..but to be able to actually use http auth I had to change the configuration template to the following:

auth_method: {{ env.get('EJABBERD_AUTH_METHOD', 'http') }}
auth_opts:
  host: {{ env.get('EJABBERD_AUTH_HOST', 'http://localhost:8000') }}
  basic_auth: {{ env.get('EJABBERD_AUTH_TOKEN', '') }}
  path_prefix: {{ env.get('EJABBERD_AUTH_PATH_PREFIX', '/internal_auth/') }}

When I run docker-compose up
I get the following error:

==> /usr/local/var/log/ejabberd/error.log <==
ejabberd_1  | 2021-02-04 13:26:37.339 [error] <0.63.0>@ejabberd_config:validate_opts:1087 Invalid value for option 'auth_method': - http
ejabberd_1  | 2021-02-04 13:26:37.339 [error] <0.63.0>@ejabberd_config:start:88 Failed to load configuration file /usr/local/etc/ejabberd/ejabberd.yml
ejabberd_1  | 2021-02-04 13:26:37.339 [critical] <0.63.0>@ejabberd_app:start:70 Failed to start ejabberd application: invalid_option
@Goutam192002
Copy link
Author

I think it's because install_modules script is run after ejabberd server has been started for the first time.
Is there a workaround for this?

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

1 participant