Duckiter will Automatically dockerize your Django projects.

Overview


Duckiter

Duckiter will Automatically dockerize your Django projects.

Requirements :

- python version : python version 3.6 or upper version
- OS : 
    - linux
    - MacOS
    - windows ( drop support )
- docker engine installed in your machine and already run through the usage of package

Installation :

clone project:

pip install duckiter

Usage :

Duckiter has two individual steps:

​ 1- initialize Dockerfile

​ 2- build image from created Dockerfile

To initialize Dockerfile (step 1) :

in terminal hit to your project directory ( where manage.py is in root ):

duckiter --init

This will create Dockerfile and config.cfg in the root of the project, and you can manipulate those files before Duckiter creates an image. If you are ok with our configurations, you can just pass '-b' to immediately build the image right after creating the Dockerfile.

duckiter --init -b

To build image (step 2) :

To build an image from the Dockerfile that has been created in the last step, you need enter:

duckiter main.py --build

this will look for config.cfg in project directory and then build the image.

Troubleshooting :

  • if you get blow error while your docker engine is already run :
[ WARNNING !!!! ] It seems your docker engine doesn't run, please run the Docker engine.

​ you can fix this issue , just enter these commands :

$ sudo groupadd docker
$ sudo usermod -aG docker $USER
$ newgrp docker

now problem fixed and you can run command again.

  • if you got error like :

    duckiter : command not found
    

    you can fix this issue by adding your python package directory into you PATH.

Contribution :

feel free to contribute to this project, but first contact me about the idea :)

You might also like...
Django-Audiofield is a simple app that allows Audio files upload, management and conversion to different audio format (mp3, wav & ogg), which also makes it easy to play audio files into your Django application.
Django-Audiofield is a simple app that allows Audio files upload, management and conversion to different audio format (mp3, wav & ogg), which also makes it easy to play audio files into your Django application.

Django-Audiofield Description: Django Audio Management Tools Maintainer: Areski Contributors: list of contributors Django-Audiofield is a simple app t

A Django app to initialize Sentry client for your Django applications

Dj_sentry This Django application intialize Sentry SDK to your Django application. How to install You can install this packaging by using: pip install

A tool to automatically fix Django deprecations.
A tool to automatically fix Django deprecations.

A tool to help upgrade Django projects to newer version of the framework by automatically fixing deprecations. The problem When maintaining a Django s

Get inside your stronghold and make all your Django views default login_required

Stronghold Get inside your stronghold and make all your Django views default login_required Stronghold is a very small and easy to use django app that

DCM is a set of tools that helps you to keep your data in your Django Models consistent.
DCM is a set of tools that helps you to keep your data in your Django Models consistent.

Django Consistency Model DCM is a set of tools that helps you to keep your data in your Django Models consistent. Motivation You have a lot of legacy

Automatically reload your browser in development.

django-browser-reload Automatically reload your browser in development. Requirements Python 3.6 to 3.10 supported. Django 2.2 to 4.0 supported. Are yo

Meta package to combine turbo-django and stimulus-django

Hotwire + Django This repository aims to help you integrate Hotwire with Django 🚀 Inspiration might be taken from @hotwired/hotwire-rails. We are sti

django-reversion is an extension to the Django web framework that provides version control for model instances.

django-reversion django-reversion is an extension to the Django web framework that provides version control for model instances. Requirements Python 3

Django project starter on steroids: quickly create a Django app AND generate source code for data models + REST/GraphQL APIs (the generated code is auto-linted and has 100% test coverage).

Create Django App 💛 We're a Django project starter on steroids! One-line command to create a Django app with all the dependencies auto-installed AND

Comments
  • Fix path exceptions in `nt` & Auto requirements.txt generator from virtual environment

    Fix path exceptions in `nt` & Auto requirements.txt generator from virtual environment

    I got an error that I tried to fix it and also added a new feature to the project that if the requirements.txt file does not exist, it will be created through the project virtual environment (if it exists) :)

    The project was tested without error on the following systems:

    • Windows 10 Enterprise
    • Manjaro Linux XFCE Edition

    About changes:

    1. When using this project on an nt system, I will encounter path errors. This is one of this errors:
    File "c:\users\Matin\appdata\local\programs\python\python38\lib\site-packages\duckiter\utility.py", line 48, in get_django_project_name
        return project_main_dir.split('/')[-2]
    IndexError: list index out of range
    

    Path separators are \\ in nt systems and / in posix systems, and you tried to separate or join the directories in the code using / and since I did this project I ran it on an nt system and os.getcwd() returns my directory to me using \\, this would cause an error.

    1. I also added automatically generate requirements.txt through the virtual environment in the project. When the requirements.txt file does not exist but the virtual environment is in the project (where manage.py exists), the requirements.txt file is automatically created by the modules installed in the virtual environment :)
    opened by ThisIsMatin 1
Releases(v0.1.9)
Owner
soroush safari
A software engineer who finds his interest in the computer world. I'm always searching for focus, a better way, and the most crucial part of life, happiness.
soroush safari
Cookiecutter Django is a framework for jumpstarting production-ready Django projects quickly.

Cookiecutter Django Powered by Cookiecutter, Cookiecutter Django is a framework for jumpstarting production-ready Django projects quickly. Documentati

Daniel Feldroy 10k Dec 31, 2022
A handy tool for generating Django-based backend projects without coding. On the other hand, it is a code generator of the Django framework.

Django Sage Painless The django-sage-painless is a valuable package based on Django Web Framework & Django Rest Framework for high-level and rapid web

sageteam 51 Sep 15, 2022
Django URL Shortener is a Django app to to include URL Shortening feature in your Django Project

Django URL Shortener Django URL Shortener is a Django app to to include URL Shortening feature in your Django Project Install this package to your Dja

Rishav Sinha 4 Nov 18, 2021
:couple: Multi-user accounts for Django projects

django-organizations Summary Groups and multi-user account management Author Ben Lopatin (http://benlopatin.com / https://wellfire.co) Status Separate

Ben Lopatin 1.1k Jan 1, 2023
Analytics services for Django projects

django-analytical The django-analytical application integrates analytics services into a Django project. Using an analytics service with a Django proj

Jazzband 1.1k Dec 31, 2022
Ugly single sign-on for django projects only

django-usso Ugly single sign-on for django projects only. Do you have many django apps with different users? Do you want to use only one of those apps

Erwin Feser 1 Mar 1, 2022
Django Fett is an incomplete code generator used on several projects

Django Fett Django Fett is an incomplete code generator used on several projects. This is an attempt to clean it up and make it public for consumption

Jeff Triplett 6 Dec 31, 2021
Django-environ allows you to utilize 12factor inspired environment variables to configure your Django application.

Django-environ django-environ allows you to use Twelve-factor methodology to configure your Django application with environment variables. import envi

Daniele Faraglia 2.7k Jan 7, 2023
pytest-django allows you to test your Django project/applications with the pytest testing tool.

pytest-django allows you to test your Django project/applications with the pytest testing tool.

pytest-dev 1.1k Dec 14, 2022
django-dashing is a customisable, modular dashboard application framework for Django to visualize interesting data about your project. Inspired in the dashboard framework Dashing

django-dashing django-dashing is a customisable, modular dashboard application framework for Django to visualize interesting data about your project.

talPor Solutions 703 Dec 22, 2022