{"id":18725582,"url":"https://github.com/reljicd/django-blog","last_synced_at":"2025-04-12T16:13:01.831Z","repository":{"id":94100338,"uuid":"113678770","full_name":"reljicd/django-blog","owner":"reljicd","description":"Simple blog web app made using Django","archived":false,"fork":false,"pushed_at":"2022-12-04T22:04:10.000Z","size":45,"stargazers_count":27,"open_issues_count":0,"forks_count":14,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-26T10:36:31.756Z","etag":null,"topics":["bash","blog","bootstrap","django","django-admin","django-orm","django-templates","django-testing","docker","python","python3","sqlite3","unittest"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/reljicd.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2017-12-09T15:14:53.000Z","updated_at":"2024-07-29T16:02:48.000Z","dependencies_parsed_at":"2023-03-05T09:00:16.015Z","dependency_job_id":null,"html_url":"https://github.com/reljicd/django-blog","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reljicd%2Fdjango-blog","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reljicd%2Fdjango-blog/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reljicd%2Fdjango-blog/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/reljicd%2Fdjango-blog/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/reljicd","download_url":"https://codeload.github.com/reljicd/django-blog/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248594136,"owners_count":21130314,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["bash","blog","bootstrap","django","django-admin","django-orm","django-templates","django-testing","docker","python","python3","sqlite3","unittest"],"created_at":"2024-11-07T14:10:52.485Z","updated_at":"2025-04-12T16:13:01.813Z","avatar_url":"https://github.com/reljicd.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Django Blog Demo\n\n## About\n\nThis is a demo project for practicing Django.\nThe idea was to build some basic blogging platform.\n\nIt was made using **Python 3.11** + **Django** and database is **SQLite**.\n**Bootstrap** was used for styling.\nTesting is done using **untitest** module.\n\nThere is a login and registration functionality included.\n\nUser has his own blog page, where he can add new blog posts. \nEvery authenticated user can comment on posts made by other users.\nHome page is paginated list of all posts.\nNon-authenticated users can see all blog posts, but cannot add new posts or comment.\n\nApp is covered with tests.\n\n## Prerequisites\n\n\\[Optional\\] Install virtual environment:\n\n```bash\n$ python -m virtualenv env\n```\n\n\\[Optional\\] Activate virtual environment:\n\nOn macOS and Linux:\n```bash\n$ source env/bin/activate\n```\n\nOn Windows:\n```bash\n$ .\\env\\Scripts\\activate\n```\n\nInstall dependencies:\n```bash\n$ pip install -r requirements.txt\n```\n\n## How to run\n\n### Default\n\nYou can run the application from the command line with manage.py.\nGo to the root folder of the application.\n\nRun migrations:\n```bash\n$ python manage.py migrate\n```\n\nInitialize data:\n```bash\n$ python manage.py loaddata users posts comments\n```\n\nRun server on port 8000:\n```bash\n$ python manage.py runserver 8000\n```\n\n#### Helper script\n\nIt is possible to run all of the above with helper script:\n\n```bash\n$ chmod +x scripts/run.sh\n$ scripts/run.sh\n```\n\n### Docker\n\nIt is also possible to run the blog app using docker:\n\nBuild the Docker image:\n```bash\n$ docker build -t reljicd/django-blog -f docker/Dockerfile .\n```\n\nRun the Docker container:\n```bash\n$ docker run --rm -i -p 8000:8000 reljicd/django-blog\n```\n\n#### Helper script\n\nIt is possible to run all of the above with helper script:\n\n```bash\n$ chmod +x scripts/run_docker.sh\n$ scripts/run_docker.sh\n```\n\n## Post Installation\n\nGo to the web browser and visit `http://localhost:8000/blog`\n\nAdmin username: **admin**\n\nAdmin password: **adminpassword**\n\nUser username: **dusan**\n\nUser password: **dusanpassword**\n\n## Helper Tools\n\n### Django Admin\n\nIt is possible to add additional admin user who can login to the admin site. Run the following command:\n```bash\n$ python manage.py createsuperuser\n```\nEnter your desired username and press enter.\n```bash\nUsername: admin_username\n```\nYou will then be prompted for your desired email address:\n```bash\nEmail address: admin@example.com\n```\nThe final step is to enter your password. You will be asked to enter your password twice, the second time as a confirmation of the first.\n```bash\nPassword: **********\nPassword (again): *********\nSuperuser created successfully.\n```\n\nGo to the web browser and visit `http://localhost:8000/admin`\n\n### Tests\n\n#### Default\nActivate virtual environment:\n\nOn macOS and Linux:\n```bash\n$ source env/bin/activate\n```\n\nOn Windows:\n```bash\n$ .\\env\\Scripts\\activate\n```\n\nRunning tests:\n```bash\n$ python manage.py test blog\n```\n\n#### Docker\n\nIt is also possible to run tests using Docker:\n\nBuild the Docker image:\n```bash\n$ docker build -t reljicd/django-blog -f docker/Dockerfile .\n```\n\nRun the Docker container:\n```bash\n$ docker run --rm reljicd/django-blog test blog\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freljicd%2Fdjango-blog","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Freljicd%2Fdjango-blog","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freljicd%2Fdjango-blog/lists"}