Django-Cookiecutter cannot start the default projectDoes Django scale?“Least Astonishment” and the Mutable Default Argumentdifferentiate null=True, blank=True in djangoCan't see django site being run in docker container on localhostDebug Django project with environment in docker containerDocker compose won't wait for Postgres to startDocker-compose can't find .env fileDockerizing existing Django projectHow do I push the multiple django-cookiecutter-made Docker images to Heroku?django runserver hangs in docker-compose up but runs correctly in docker-compose run

What's the safest way to inform a new user of their password on my web site?

Can a single server be associated with multiple domains?

Mean Value Theorem: Continuous or Defined?

What exactly is a fey/fiend/celestial spirit?

Which centaur is more 'official'?

How do I delete a Bitcoin full node from my hard drive?

Fluently Validation of Objects

Can I travel from Germany to England alone as an unaccompanied minor?

Prevent cacls asking for confirmation?

In F1 classification, what is ON?

Why transcripts instead of degree certificates?

The Starks, Parks, Clarks and their kids

How do I reference other list in calculated column?

Most importants new papers in computational complexity

Is this hogweed?

Why did this meteor appear cyan?

Procedurally generate regions on island

What is the olden name for sideburns?

In the context of a differentiator circuit, what is a “current-sensing resistor”?

Can the passive "être + verbe" sometimes mean the past?

Java Optional working of orElse is not as if else

What is the difference between x RadToDeg cos x div and COSC?

How can my story take place on Earth without referring to our existing cities and countries?

What does grep -v "grep" mean and do?



Django-Cookiecutter cannot start the default project


Does Django scale?“Least Astonishment” and the Mutable Default Argumentdifferentiate null=True, blank=True in djangoCan't see django site being run in docker container on localhostDebug Django project with environment in docker containerDocker compose won't wait for Postgres to startDocker-compose can't find .env fileDockerizing existing Django projectHow do I push the multiple django-cookiecutter-made Docker images to Heroku?django runserver hangs in docker-compose up but runs correctly in docker-compose run






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








2















I am trying to start a fresh project with django-cookiectter, it builds fine but when i am trying to docker-compose -f local.yml up it gives me this error on django's service:



django_1 | * Running on http://0.0.0.0:8000/ (Press CTRL+C to quit)
django_1 | * Restarting with stat
': No such file or directorycute 'python
dj_ekiosk_django_1 exited with code 127
Gracefully stopping... (press Ctrl+C again to force)
Stopping dj_ekiosk_postgres_1 ... done


This is the local.yml file which i am trying to run (nothing changed its straight out of the cookiecutter project)



local.yml
version: '3'

volumes:
local_postgres_data:
local_postgres_data_backups:

services:
django:
build:
context: .
dockerfile: ./compose/local/django/Dockerfile
image: dj_ekiosk_local_django
depends_on:
- postgres
volumes:
- .:/app
env_file:
- ./.envs/.local/.django
- ./.envs/.local/.postgres
ports:
- "8000:8000"
command: /start

postgres:
build:
context: .
dockerfile: ./compose/production/postgres/Dockerfile
image: dj_ekiosk_production_postgres
volumes:
- local_postgres_data:/var/lib/postgresql/data
- local_postgres_data_backups:/backups
env_file:
- ./.envs/.local/.postgres









share|improve this question
























  • try with sudo docker-compose -f local.yml up

    – Devang Padhiyar
    Mar 25 at 12:22











  • Using windows, same thing happens when I run it as administrator.

    – iseedeadpeople
    Mar 25 at 12:29






  • 1





    Providing the local.yml-file would probably help you in getting answers. As it is you're providing error logs and nothing else tangible. Creating a question that is Minimal, Complete and verifiable will increase your chances of getting an useful answer.

    – Christian W.
    Mar 25 at 12:35












  • @ChristianW. The local.yml is straight out of the django-cookitecutter I haven't changed anything thats why I said 'fresh'. However I've put it for more convenience.

    – iseedeadpeople
    Mar 25 at 12:42






  • 1





    Did you create this cookiecutter project for Windows? It asks you if it is for windows when you create. You are developing on windows but running on linux container. Normally it is not a problem, but in this case this might be the reason for this error somehow. Do you have a line like #!/usr/bin/python in your manage.py, if so can you add this line here and do you have any import statement for windws like: C:user... ?

    – zeynel
    Mar 25 at 13:03


















2















I am trying to start a fresh project with django-cookiectter, it builds fine but when i am trying to docker-compose -f local.yml up it gives me this error on django's service:



django_1 | * Running on http://0.0.0.0:8000/ (Press CTRL+C to quit)
django_1 | * Restarting with stat
': No such file or directorycute 'python
dj_ekiosk_django_1 exited with code 127
Gracefully stopping... (press Ctrl+C again to force)
Stopping dj_ekiosk_postgres_1 ... done


This is the local.yml file which i am trying to run (nothing changed its straight out of the cookiecutter project)



local.yml
version: '3'

volumes:
local_postgres_data:
local_postgres_data_backups:

services:
django:
build:
context: .
dockerfile: ./compose/local/django/Dockerfile
image: dj_ekiosk_local_django
depends_on:
- postgres
volumes:
- .:/app
env_file:
- ./.envs/.local/.django
- ./.envs/.local/.postgres
ports:
- "8000:8000"
command: /start

postgres:
build:
context: .
dockerfile: ./compose/production/postgres/Dockerfile
image: dj_ekiosk_production_postgres
volumes:
- local_postgres_data:/var/lib/postgresql/data
- local_postgres_data_backups:/backups
env_file:
- ./.envs/.local/.postgres









share|improve this question
























  • try with sudo docker-compose -f local.yml up

    – Devang Padhiyar
    Mar 25 at 12:22











  • Using windows, same thing happens when I run it as administrator.

    – iseedeadpeople
    Mar 25 at 12:29






  • 1





    Providing the local.yml-file would probably help you in getting answers. As it is you're providing error logs and nothing else tangible. Creating a question that is Minimal, Complete and verifiable will increase your chances of getting an useful answer.

    – Christian W.
    Mar 25 at 12:35












  • @ChristianW. The local.yml is straight out of the django-cookitecutter I haven't changed anything thats why I said 'fresh'. However I've put it for more convenience.

    – iseedeadpeople
    Mar 25 at 12:42






  • 1





    Did you create this cookiecutter project for Windows? It asks you if it is for windows when you create. You are developing on windows but running on linux container. Normally it is not a problem, but in this case this might be the reason for this error somehow. Do you have a line like #!/usr/bin/python in your manage.py, if so can you add this line here and do you have any import statement for windws like: C:user... ?

    – zeynel
    Mar 25 at 13:03














2












2








2








I am trying to start a fresh project with django-cookiectter, it builds fine but when i am trying to docker-compose -f local.yml up it gives me this error on django's service:



django_1 | * Running on http://0.0.0.0:8000/ (Press CTRL+C to quit)
django_1 | * Restarting with stat
': No such file or directorycute 'python
dj_ekiosk_django_1 exited with code 127
Gracefully stopping... (press Ctrl+C again to force)
Stopping dj_ekiosk_postgres_1 ... done


This is the local.yml file which i am trying to run (nothing changed its straight out of the cookiecutter project)



local.yml
version: '3'

volumes:
local_postgres_data:
local_postgres_data_backups:

services:
django:
build:
context: .
dockerfile: ./compose/local/django/Dockerfile
image: dj_ekiosk_local_django
depends_on:
- postgres
volumes:
- .:/app
env_file:
- ./.envs/.local/.django
- ./.envs/.local/.postgres
ports:
- "8000:8000"
command: /start

postgres:
build:
context: .
dockerfile: ./compose/production/postgres/Dockerfile
image: dj_ekiosk_production_postgres
volumes:
- local_postgres_data:/var/lib/postgresql/data
- local_postgres_data_backups:/backups
env_file:
- ./.envs/.local/.postgres









share|improve this question
















I am trying to start a fresh project with django-cookiectter, it builds fine but when i am trying to docker-compose -f local.yml up it gives me this error on django's service:



django_1 | * Running on http://0.0.0.0:8000/ (Press CTRL+C to quit)
django_1 | * Restarting with stat
': No such file or directorycute 'python
dj_ekiosk_django_1 exited with code 127
Gracefully stopping... (press Ctrl+C again to force)
Stopping dj_ekiosk_postgres_1 ... done


This is the local.yml file which i am trying to run (nothing changed its straight out of the cookiecutter project)



local.yml
version: '3'

volumes:
local_postgres_data:
local_postgres_data_backups:

services:
django:
build:
context: .
dockerfile: ./compose/local/django/Dockerfile
image: dj_ekiosk_local_django
depends_on:
- postgres
volumes:
- .:/app
env_file:
- ./.envs/.local/.django
- ./.envs/.local/.postgres
ports:
- "8000:8000"
command: /start

postgres:
build:
context: .
dockerfile: ./compose/production/postgres/Dockerfile
image: dj_ekiosk_production_postgres
volumes:
- local_postgres_data:/var/lib/postgresql/data
- local_postgres_data_backups:/backups
env_file:
- ./.envs/.local/.postgres






python django docker






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 25 at 12:53







iseedeadpeople

















asked Mar 25 at 12:14









iseedeadpeopleiseedeadpeople

548 bronze badges




548 bronze badges












  • try with sudo docker-compose -f local.yml up

    – Devang Padhiyar
    Mar 25 at 12:22











  • Using windows, same thing happens when I run it as administrator.

    – iseedeadpeople
    Mar 25 at 12:29






  • 1





    Providing the local.yml-file would probably help you in getting answers. As it is you're providing error logs and nothing else tangible. Creating a question that is Minimal, Complete and verifiable will increase your chances of getting an useful answer.

    – Christian W.
    Mar 25 at 12:35












  • @ChristianW. The local.yml is straight out of the django-cookitecutter I haven't changed anything thats why I said 'fresh'. However I've put it for more convenience.

    – iseedeadpeople
    Mar 25 at 12:42






  • 1





    Did you create this cookiecutter project for Windows? It asks you if it is for windows when you create. You are developing on windows but running on linux container. Normally it is not a problem, but in this case this might be the reason for this error somehow. Do you have a line like #!/usr/bin/python in your manage.py, if so can you add this line here and do you have any import statement for windws like: C:user... ?

    – zeynel
    Mar 25 at 13:03


















  • try with sudo docker-compose -f local.yml up

    – Devang Padhiyar
    Mar 25 at 12:22











  • Using windows, same thing happens when I run it as administrator.

    – iseedeadpeople
    Mar 25 at 12:29






  • 1





    Providing the local.yml-file would probably help you in getting answers. As it is you're providing error logs and nothing else tangible. Creating a question that is Minimal, Complete and verifiable will increase your chances of getting an useful answer.

    – Christian W.
    Mar 25 at 12:35












  • @ChristianW. The local.yml is straight out of the django-cookitecutter I haven't changed anything thats why I said 'fresh'. However I've put it for more convenience.

    – iseedeadpeople
    Mar 25 at 12:42






  • 1





    Did you create this cookiecutter project for Windows? It asks you if it is for windows when you create. You are developing on windows but running on linux container. Normally it is not a problem, but in this case this might be the reason for this error somehow. Do you have a line like #!/usr/bin/python in your manage.py, if so can you add this line here and do you have any import statement for windws like: C:user... ?

    – zeynel
    Mar 25 at 13:03

















try with sudo docker-compose -f local.yml up

– Devang Padhiyar
Mar 25 at 12:22





try with sudo docker-compose -f local.yml up

– Devang Padhiyar
Mar 25 at 12:22













Using windows, same thing happens when I run it as administrator.

– iseedeadpeople
Mar 25 at 12:29





Using windows, same thing happens when I run it as administrator.

– iseedeadpeople
Mar 25 at 12:29




1




1





Providing the local.yml-file would probably help you in getting answers. As it is you're providing error logs and nothing else tangible. Creating a question that is Minimal, Complete and verifiable will increase your chances of getting an useful answer.

– Christian W.
Mar 25 at 12:35






Providing the local.yml-file would probably help you in getting answers. As it is you're providing error logs and nothing else tangible. Creating a question that is Minimal, Complete and verifiable will increase your chances of getting an useful answer.

– Christian W.
Mar 25 at 12:35














@ChristianW. The local.yml is straight out of the django-cookitecutter I haven't changed anything thats why I said 'fresh'. However I've put it for more convenience.

– iseedeadpeople
Mar 25 at 12:42





@ChristianW. The local.yml is straight out of the django-cookitecutter I haven't changed anything thats why I said 'fresh'. However I've put it for more convenience.

– iseedeadpeople
Mar 25 at 12:42




1




1





Did you create this cookiecutter project for Windows? It asks you if it is for windows when you create. You are developing on windows but running on linux container. Normally it is not a problem, but in this case this might be the reason for this error somehow. Do you have a line like #!/usr/bin/python in your manage.py, if so can you add this line here and do you have any import statement for windws like: C:user... ?

– zeynel
Mar 25 at 13:03






Did you create this cookiecutter project for Windows? It asks you if it is for windows when you create. You are developing on windows but running on linux container. Normally it is not a problem, but in this case this might be the reason for this error somehow. Do you have a line like #!/usr/bin/python in your manage.py, if so can you add this line here and do you have any import statement for windws like: C:user... ?

– zeynel
Mar 25 at 13:03













1 Answer
1






active

oldest

votes


















1














You probably have rn(CRLF) line endings in your manage.py, which is default for windows but causes error under Linux. The first line in your manage.py should be something like this:



#!/usr/bin/env python/r/n


you probably dont see /r/n part when you open the source code with a text editor/IDE but it is there. What you should do is convert CRLF line ending to LF line ending (which works for Linux). There are tools for doing that, and since you are developing on Windows, i would suggest configuring your IDE to use LF for line endings. (It is really easy to configure them with PyCharm, Visual Studio Code etc..)






share|improve this answer























  • Thank you! I've changed the Line Separator to Unix and OSX (n) (LF) in pycharm in the global settings and everything worked out!

    – iseedeadpeople
    Mar 25 at 16:27










Your Answer






StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













draft saved

draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55337574%2fdjango-cookiecutter-cannot-start-the-default-project%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









1














You probably have rn(CRLF) line endings in your manage.py, which is default for windows but causes error under Linux. The first line in your manage.py should be something like this:



#!/usr/bin/env python/r/n


you probably dont see /r/n part when you open the source code with a text editor/IDE but it is there. What you should do is convert CRLF line ending to LF line ending (which works for Linux). There are tools for doing that, and since you are developing on Windows, i would suggest configuring your IDE to use LF for line endings. (It is really easy to configure them with PyCharm, Visual Studio Code etc..)






share|improve this answer























  • Thank you! I've changed the Line Separator to Unix and OSX (n) (LF) in pycharm in the global settings and everything worked out!

    – iseedeadpeople
    Mar 25 at 16:27















1














You probably have rn(CRLF) line endings in your manage.py, which is default for windows but causes error under Linux. The first line in your manage.py should be something like this:



#!/usr/bin/env python/r/n


you probably dont see /r/n part when you open the source code with a text editor/IDE but it is there. What you should do is convert CRLF line ending to LF line ending (which works for Linux). There are tools for doing that, and since you are developing on Windows, i would suggest configuring your IDE to use LF for line endings. (It is really easy to configure them with PyCharm, Visual Studio Code etc..)






share|improve this answer























  • Thank you! I've changed the Line Separator to Unix and OSX (n) (LF) in pycharm in the global settings and everything worked out!

    – iseedeadpeople
    Mar 25 at 16:27













1












1








1







You probably have rn(CRLF) line endings in your manage.py, which is default for windows but causes error under Linux. The first line in your manage.py should be something like this:



#!/usr/bin/env python/r/n


you probably dont see /r/n part when you open the source code with a text editor/IDE but it is there. What you should do is convert CRLF line ending to LF line ending (which works for Linux). There are tools for doing that, and since you are developing on Windows, i would suggest configuring your IDE to use LF for line endings. (It is really easy to configure them with PyCharm, Visual Studio Code etc..)






share|improve this answer













You probably have rn(CRLF) line endings in your manage.py, which is default for windows but causes error under Linux. The first line in your manage.py should be something like this:



#!/usr/bin/env python/r/n


you probably dont see /r/n part when you open the source code with a text editor/IDE but it is there. What you should do is convert CRLF line ending to LF line ending (which works for Linux). There are tools for doing that, and since you are developing on Windows, i would suggest configuring your IDE to use LF for line endings. (It is really easy to configure them with PyCharm, Visual Studio Code etc..)







share|improve this answer












share|improve this answer



share|improve this answer










answered Mar 25 at 14:21









zeynelzeynel

6203 silver badges12 bronze badges




6203 silver badges12 bronze badges












  • Thank you! I've changed the Line Separator to Unix and OSX (n) (LF) in pycharm in the global settings and everything worked out!

    – iseedeadpeople
    Mar 25 at 16:27

















  • Thank you! I've changed the Line Separator to Unix and OSX (n) (LF) in pycharm in the global settings and everything worked out!

    – iseedeadpeople
    Mar 25 at 16:27
















Thank you! I've changed the Line Separator to Unix and OSX (n) (LF) in pycharm in the global settings and everything worked out!

– iseedeadpeople
Mar 25 at 16:27





Thank you! I've changed the Line Separator to Unix and OSX (n) (LF) in pycharm in the global settings and everything worked out!

– iseedeadpeople
Mar 25 at 16:27






Got a question that you can’t ask on public Stack Overflow? Learn more about sharing private information with Stack Overflow for Teams.








Got a question that you can’t ask on public Stack Overflow? Learn more about sharing private information with Stack Overflow for Teams.




















draft saved

draft discarded
















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55337574%2fdjango-cookiecutter-cannot-start-the-default-project%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

SQL error code 1064 with creating Laravel foreign keysForeign key constraints: When to use ON UPDATE and ON DELETEDropping column with foreign key Laravel error: General error: 1025 Error on renameLaravel SQL Can't create tableLaravel Migration foreign key errorLaravel php artisan migrate:refresh giving a syntax errorSQLSTATE[42S01]: Base table or view already exists or Base table or view already exists: 1050 Tableerror in migrating laravel file to xampp serverSyntax error or access violation: 1064:syntax to use near 'unsigned not null, modelName varchar(191) not null, title varchar(191) not nLaravel cannot create new table field in mysqlLaravel 5.7:Last migration creates table but is not registered in the migration table

용인 삼성생명 블루밍스 목차 통계 역대 감독 선수단 응원단 경기장 같이 보기 외부 링크 둘러보기 메뉴samsungblueminx.comeh선수 명단용인 삼성생명 블루밍스용인 삼성생명 블루밍스ehsamsungblueminx.comeheheheh

155 수학 과학 기타 둘러보기 메뉴eh추가해eh문서를 완성해