{"id":21983054,"url":"https://github.com/arsho/paniyo","last_synced_at":"2026-04-15T14:02:08.886Z","repository":{"id":79174260,"uuid":"140806196","full_name":"arsho/paniyo","owner":"arsho","description":null,"archived":false,"fork":false,"pushed_at":"2018-08-01T11:37:58.000Z","size":11,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-23T01:34:40.209Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/arsho.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-07-13T06:25:48.000Z","updated_at":"2018-08-01T11:38:00.000Z","dependencies_parsed_at":"2023-05-18T01:46:44.248Z","dependency_job_id":null,"html_url":"https://github.com/arsho/paniyo","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/arsho/paniyo","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arsho%2Fpaniyo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arsho%2Fpaniyo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arsho%2Fpaniyo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arsho%2Fpaniyo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/arsho","download_url":"https://codeload.github.com/arsho/paniyo/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arsho%2Fpaniyo/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31844329,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-15T13:28:40.153Z","status":"ssl_error","status_checked_at":"2026-04-15T13:28:29.396Z","response_time":63,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-29T17:34:17.567Z","updated_at":"2026-04-15T14:02:08.871Z","avatar_url":"https://github.com/arsho.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"Django MySQL Application in Minishift\n=========================================\nDeploy a Django MySQL application in Minishift.\n\n### Prerequisites\n- Minishift\n- OC Tools\n\nYou can install these tools by following [this gist](https://gist.github.com/arsho/919d6704ec2838f1b4b25b7e3b61a2f9#file-minishift_installation-md)\n\n### Installation Procedure\n#### MySQL\n- Create new application for MySQL from Catalogue page. For me the URL was [https://192.168.99.100:8443/console/catalog](https://192.168.99.100:8443/console/catalog)\n  \n  ![alt Install MySQL Application from catalogue](https://s8.postimg.cc/6znxejpqt/install_mysql.png)\n  \n- Configuring MySQL username, password and database name\n    ```bash\n    Database Service Name: paniyomysql\n    MySQL Connection Username: paniyo\n    MySQL Connection Password: 123\n    MySQL root user Password: 123\n    MySQL Database Name: paniyo_db\n    Volume Capacity: 512mi\n    Version of MySQL Image: 5.7\n    ```\n  \n  ![alt MySQL configuration](https://s8.postimg.cc/pt9qbmg9x/mysql_configuration.png)\n  \n  After successful installation it will show connection information:\n    ```bash\n    The following service(s) have been created in your project: paniyomysql.\n            Username: paniyo\n            Password: 123\n       Database Name: paniyo_db\n      Connection URL: mysql://paniyomysql:3306/\n    ```\n- To use this MySQL database in Django project we need to get the IP address. The IP address of this MySQL service can be found in ```YOUR PROJECT \u003e Applications \u003e Pods \u003e Running Pod with paniyomysql name \u003e IP```. For me the IP address is: 172.17.0.4\n\n#### Django\n- You can deploy any Django application in Minishift by modifying few things. You can clone my dummy Django application with necessary modification for Minishift from [https://github.com/arsho/paniyo](https://github.com/arsho/paniyo)\n- Modification:\n  - Update database information in ```settings.py``` file:\n    ```python\n    DATABASES = {\n        'default': {\n            'ENGINE': 'django.db.backends.mysql',\n            'NAME': 'paniyo_db',\n            'USER': 'paniyo',\n            'PASSWORD': '123',\n            'HOST': '172.17.0.4',\n            'PORT': '3306'\n        }\n    }\n    ```\n  - Allow all hosts in ```settings.py``` file:\n    ```python\n    ALLOWED_HOSTS=['*']\n    ```\n  - Dockerfile (it is based on my project, modify if necessary) : [sample dockerfile](https://raw.githubusercontent.com/arsho/paniyo/master/Dockerfile)\n- Push the Django application to Github.\n- Deploy Django to Openshift\n  - A Django application can be deployed to Openshift in several ways (REF DEPLOY). We will show how we can deploy Django application from Github (REF NEW APP).\n  - To deploy Django application from Github use:\n    ```bash\n    oc new-app URL_TO_GITHUB_REPOSITORY\n    ```\n    In our case it is:  \n    ```bash\n    oc new-app https://github.com/arsho/paniyo\n    ```\n    The build process may fail due to low bandwidth. So, make sure you have at least 1000 KiB/s bandwidth. \n  - Routes External Traffic: Create route to make the application accessible.\n    Set the route from ```YOUR PROJECT \u003e Applications \u003e Routes \u003e Create Route```\n- Create superuser\n  - To create super user go to ```YOUR PROJECT \u003e Applications \u003e Pods \u003e Running Pod \u003e Terminal```. Then create super user using \n    ```bash\n    python manage.py createsuperuser\n    ```\n    \n    ![alt create super user](https://s15.postimg.cc/tbrilopff/create_super_user.png)\n    \n- Access Application\n  - The URL to access the application can be found in the route we have created earlier. \n  \n    ![alt application admin panel](https://s15.postimg.cc/lkasnd5x7/admin_panel.png)\n  \n- Create Storage and attach it to Django Application\n  - The application needs static storage to allow uploading files.\n  - Create storage from ```YOUR PROJECT \u003e Storage``` like below:\n  \n    ![alt add storage](https://s15.postimg.cc/kjajyjmgb/add_storage.png)\n  \n  - Attach this storage to the Django application from ```YOUR PROJECT \u003e Applications \u003e Deployments \u003e Running Pod \u003e Configuration``` like:\n  \n    ![alt attach storage](https://s15.postimg.cc/abwlzma3v/attach_storage.png)\n  \n    Enter ```/src/data``` in mount path:\n\n    ![alt attach storage to Django](https://s15.postimg.cc/folgdh32j/add_storage_to_django.png)\n    \n### Running application:\n\n![alt site screenshot](https://s15.postimg.cc/5jmsnya8b/site_image.png)\n\n\u003chr\u003e\n\n#### Make commands\n- make migrations\n- make migrate\n- make run\n\n#### How this application is created using Django?\n```Bash\npython3 -m virtualenv venv --no-site-packages\nsource venv/bin/activate\npip install -r requirements.txt\ndjango-admin startproject paniyosite\npaniyo cd paniyosite\npython manage.py startapp product_information\n```\n\u003chr\u003e\n\n#### Author\n- [Ahmedur Rahman Shovon](https://arsho.github.io)\n\n#### References\n\n* Blog - Deploy Django to Openshift 3 Powered by MySQL and Gunicorn: [http://ruddra.com/2018/02/24/deploy-django-to-openshift-3/](http://ruddra.com/2018/02/24/deploy-django-to-openshift-3/)\n* New App - Official documentation: [https://docs.openshift.com/enterprise/3.1/dev_guide/new_app.html](https://docs.openshift.com/enterprise/3.1/dev_guide/new_app.html)\n* Deploy - Official documentation: [https://docs.openshift.com/enterprise/3.0/dev_guide/deployments.html](https://docs.openshift.com/enterprise/3.0/dev_guide/deployments.html)\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Farsho%2Fpaniyo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Farsho%2Fpaniyo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Farsho%2Fpaniyo/lists"}