-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Got endOfInput even if config file is mapped and readable #937
Comments
some update: i think it was due to invalid config file. After i populated all the envvars the problem goes away. I think it'll be helpful to output more explanatory error messages in this case. |
I'm seeing this message despite an hour or two trying to solve it. Populating all envvars doesn't change the outcome for me. Running the released docker v0.4.2.0. @jimexist any chance you can share your configs (dockerfile+postgrest.conf)? I've checked against various issues/docs as well (hardcoding False for secret-is-base64 fixed the TypeError). I'll try out head of master now. |
@jlsphar i'm just filling out all the envvars with values in the config then i'm all good |
@jlsphar in the project chat @jcasto reported the same problem. Can you try running the file myfile.conf I'm curious if it will report a different encoding than I see locally for my own config file that works properly. |
I am also fighting this problem. |
It would appear that my password for my user was too complex, and the special characters in the file were causing the binary to not function as expected. |
I have the same problem and solved by manually create a new file and typing all the lines in the file. |
Greetings, I had this issue as well, turned out that I was using single quotes (') to quote my strings. Ensure that you are using double quotes ("). |
@robx Have you seen a similar issue happen with configurator-pg? |
This is still a problem. I think our configuration format is pretty similar to TOML. So we could try tomland and see how it fares. It looks more actively maintained. |
@steve-chavez I haven't seen similar issues, but I'm also not really sure what the issue is here. I.e., there might well be some concrete issue where some wrongly quoted fields cause an unhelpful error message. I'd be happy to address such. As it stands, the issue is very vague to me. |
@robx For now, I can reproduce the single quote issue: ## postgrest.conf
## ..
app.settings.external_api_secret = 'some_value'
## Will cause
postgrest postgrest.conf
Error parsing config file:
parsing support/configs/config: endOfInput Though the main issue here is related to env var interpolation. In PostgREST/postgrest-heroku#25 (comment) it's mentioned that a config like: export TEST=".\"https://somedomain.example/key\""
## postgrest.conf
app.settings.external_api_secret = "$(TEST)" Would cause the @Fohlen could you provide a sample config that fails? |
So it looks like due to the use of attoparsec any parse error will backtrack back to |
The config error messages should be more descriptive now that #1457 got merged. I'll close for now but will reopen if unclear errors are reported again. |
This is pertaining to docker v0.4.2.0
The text was updated successfully, but these errors were encountered: