The most popular Cookiecutter-based framework for jumpstarting production-ready Django projects quickly
browniebroke on pyup-update-django-extensions-2.1.4-to-2.1.5
browniebroke on master
Update django-extensions from 2… Merge pull request #1916 from p… (compare)
browniebroke on pyup-update-flake8-3.6.0-to-3.7.3
browniebroke on master
Update flake8 from 3.6.0 to 3.7… Update flake8 from 3.6.0 to 3.7… Merge pull request #1920 from p… (compare)
browniebroke on pyup-update-pytest-4.1.1-to-4.2.0
browniebroke on master
Update pytest from 4.1.1 to 4.2… Update pytest from 4.1.1 to 4.2… Merge pull request #1919 from p… (compare)
pydanny on pyup-update-flake8-3.6.0-to-3.7.2
pydanny on pyup-update-flake8-3.6.0-to-3.7.3
Update flake8 from 3.6.0 to 3.7… (compare)
pydanny on pyup-update-flake8-3.6.0-to-3.7.3
pydanny on pyup-update-flake8-3.6.0-to-3.7.3
Update flake8 from 3.6.0 to 3.7… (compare)
pydanny on pyup-update-pytest-4.1.1-to-4.2.0
Update pytest from 4.1.1 to 4.2… (compare)
I'm new to docker, cookiecutter, and this stuff. Very familiar with Django, pretty familiar with SCSS/SASS/LESS->CSS, and transpiling into JS. I've got a new project, created with cookiecutter-django, running in PyCharm via Docker - and it's a beautiful thing...
But how/why isn't gulp/scss->css/js transpiling baked into this project to 'just work'? It seems like it asks the right question on startup (re: js task runner/gulp). Looks like there are a couple of (long-standing?) PRs relating to gulp+docker, a couple relating to webpack too.
Looking to get my TailwindCSS going on, maybe a little Typescript, yo!
Remember, I'm new to docker and gulp... save me people!
@browniebroke I am worried about loosing data in docker environment but I also tried docker build and getting this error.
time="2019-04-01T16:04:06Z" level=error msg="Unable to obtain ACME certificate for domains \"ijackcrack.com\" detected thanks to rule \"Host:ijackcrack.com\" : unable to generate a certificate for the domains [ijackcrack.com]: acme: Error -> One or more domains had a problem:\n[ijackcrack.com] acme: error: 400 :: urn:ietf:params:acme:error:connection :: Fetching http://ijackcrack.com/.well-known/acme-challenge/KewQchS5fzcKYonHz6Lhnz0AvRFjI7vUHuxZ9NfWEqE: Timeout during connect (likely firewall problem), url: \n"
@browniebroke Interested in the above question as well.
Is it possible to use a standalone postgres database ?
Will it work if I pass DATABASE_URL variable in .postgres env or in production config.
I have a digitalocean postgres instance running with some existing bots, and I want my django app to share same database with my Telegram bot.
@browniebroke What is the correct way to make migrations while using a docker environment.
If I make changes locally -> push to repository -> Git pull on server -> docker-compose build -> docker-compose up -> docker-compose run --rm django python manage.py migrate
I get this error:
’’’
Your models have changes that are not yet reflected in a migration, and so won't be applied.
Run 'manage.py makemigrations' to make new migrations, and then re-run 'manage.py migrate' to apply them.
’’’
docker-compose run --rm django python manage.py makemigrations
builds the required migrations, but migrate command again gives the same error.
Seems I need to makemigrations before pushing to git, but then I have to set .env file with all required variables Database, celery in addition of docker environment.
<script async src="https://telegram.org/js/telegram-widget.js?5" data-telegram-login="MySamplebot" data-size="large" data-auth-url="https://mywebsite.com/users/tgauth" data-request-access="write"></script>
My website works all good with non www version but the www.example.com version gives me 404 error and also SSL does not work
I have A record set for www and @ to my server IP
Have ".mydomain.com" in allowed host
What can be the issue?
Could not install packages due to an EnvironmentError: [Errno 22] Invalid argument: '/usr/local/lib/python3.6/site-packages/wheel-0.33.1.dist-info/
, but in base.txt I got this: wheel==0.29.0
. Then I build the image on my machine and upload to docker-hub, and download the image on production instead of build, but now I get the Postgres is not available
, but If I connect to the django container and run the code of postgres_ready()
(defined in django/entrypoint.sh) I can connect to postgres. Any clue?
.env
? or the content of the .env
are copied to the image on build and can be delete on production? thanks for the help.
I have plans to write an app using cookiecutter-django that serves some large static files to authenticated users only. The files are too big to wrap in a Django file response, and must only be accessible to authenticated users.
I did this before with a project that I migrated to cookiecutter-django when you were using Caddy. The change at that point was simple. Caddy uses the same header as nginx, the X-Accel-Redirect
header, to tell the proxy to serve an otherwise inaccessible file instead of forwarding the response. (Here's a good description of the config required with nginx; it's not very different with Caddy -- https://wellfire.co/learn/nginx-django-x-accel-redirects/)
I have no idea how to accomplish the same thing with Traefik, and it appears it may not be possible at all since Traefik isn't actually a web server. Does anyone have recommendations on how to make this work with cookiecutter-django? Does this mean I just can't use it for projects like these?
python3 manage.py createsuperuser
?
AWS Lambda
. And I have to dispatch a long running job to child process. What is the best practice on this problem?
this is the traceback...everything runs well until it gets to the postgres image
Creating CA: /home/circleci/.docker/machine/certs/ca.pem
Creating client certificate: /home/circleci/.docker/machine/certs/cert.pem
Running pre-create checks...
Creating machine...
(***-api) Importing SSH key...
Waiting for machine to be running, this may take a few minutes...
Detecting operating system of created instance...
Waiting for SSH to be available...
Detecting the provisioner...
Provisioning with ubuntu(systemd)...
Installing Docker...
Copying certs to the local machine directory...
Copying certs to the remote machine...
Setting Docker configuration on the remote daemon...
Checking connection to Docker...
Docker is up and running!
To see how to connect your Docker Client to the Docker Engine running on this virtual machine, run: docker-machine env ***-api
redis uses an image, skipping
Building postgres
ERROR: SSL error: [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:661)
Exited with code 1
I haven't made any changes to the docker configs that come with cookiecutter