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

backend does not start, even after changing line endings from CRLF to LF manually #248

Closed
pranjalsrv opened this issue Aug 13, 2020 · 3 comments
Labels

Comments

@pranjalsrv
Copy link

pranjalsrv commented Aug 13, 2020

This is in the output of command docker-compose logs:

backend_1  | There is no script /app/prestart.sh
backend_1  | INFO:     Uvicorn running on http://0.0.0.0:80 (Press CTRL+C to quit)
backend_1  | INFO:     Started reloader process [1] using statreload
backend_1  | ERROR:    Error loading ASGI app. Import string ":app" must be in format "<module>:<attribute>".

This issue still persists on running on Windows. It is the duplicate of closed issue #90, merged by PR #149
I tried changing the line endings using both VSCode and manually using the command:find . -type f -exec dos2unix {} \;, but the issue still exists. So the closed issue in #13 is not working as well.

I am able to create a bash session in the backend container:

> docker-compose exec backend bash
WARNING: Some services (backend, db, pgadmin, proxy) use the 'deploy' key, which will be ignored. Compose does not support 'deploy' configuration - use `docker stack deploy` to deploy to a swarm.
root@7bf80e8eb31a:/app#

I can access the Traefik and pgAdmin endpoints, but can't login using the API, or use the API endpoints.

@hoorayboo
Copy link

I've had this same issue. At first, it appeared to be a CRLF -> LF issue on windows. To that end, have you tried the commands:
git config --global core.autocrlf true
git add --renormalize .

That fixed the issue the first time it appeared for me. If that doesn't fix the issue, then may I ask if you are using the Docker Dashboard GUI to stop your Docker stack? I was, and this issue kept coming back for me. I had to switch to using the command line to stop the stack. Hope that helps.

@tiangolo
Copy link
Member

tiangolo commented Dec 6, 2020

A recent update of this project generator modifies the files after the project generation to replace those newline characters. Do you still have issues with a freshly generated project?

@github-actions
Copy link

Assuming the original issue was solved, it will be automatically closed now. But feel free to add more comments or create new issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants