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

docker compose: config.yml is a folder #289

Closed
campoy opened this issue Sep 25, 2018 · 3 comments
Closed

docker compose: config.yml is a folder #289

campoy opened this issue Sep 25, 2018 · 3 comments
Assignees

Comments

@campoy
Copy link
Contributor

campoy commented Sep 25, 2018

Due to the way config.yml is mounted into to Docker, when the file doesn't exist in the current directory it is mounted as an empty directory.

This leads to the following error message:

lookout_1   | Can't open configuration file: read config.yml: is a directory

I propose solving this by either:

  • providing an empty config.yml, or
  • changing the code to ignore config.yml if it's not a file.
@carlosms
Copy link
Contributor

The error message could be improved to be more user-friendly, but having a default working config.yml is unfortunately not possible. Not all the config options can be set with an env var, and some are required to work.

You need to set at least the analyzers, otherwise we won't produce any comments.
And also the repos to watch are set in there. For user & token you also need repositories. And for github app auth, app_id and private_key.

@campoy
Copy link
Contributor Author

campoy commented Oct 10, 2018

I think the problem is that when the file doesn't exist it ends up being created as a directory.
Is there any way to avoid that behavior?

I'd rather have an error saying something like "no analyzers found in config.yml" than this

@carlosms
Copy link
Contributor

I couldn't find a way to detect the file before launching the containers, so in #320 I've added a better error message for this specific scenario.

@carlosms carlosms self-assigned this Oct 11, 2018
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