{"id":19217732,"url":"https://github.com/rikardfahlstrom/padel-page","last_synced_at":"2026-04-04T20:32:37.582Z","repository":{"id":40444564,"uuid":"468724788","full_name":"RikardFahlstrom/padel-page","owner":"RikardFahlstrom","description":"A webpage where users can add booked padel slots and sign up for slots where they can join.","archived":false,"fork":false,"pushed_at":"2022-11-04T12:07:27.000Z","size":262,"stargazers_count":0,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-07-29T17:33:17.262Z","etag":null,"topics":["docker","dynamodb","flask","nginx","nginx-proxy","python","rollbar"],"latest_commit_sha":null,"homepage":"http://padelplanner.work/","language":"CSS","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/RikardFahlstrom.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}},"created_at":"2022-03-11T11:31:09.000Z","updated_at":"2022-05-10T08:56:34.000Z","dependencies_parsed_at":"2023-01-21T22:04:02.101Z","dependency_job_id":null,"html_url":"https://github.com/RikardFahlstrom/padel-page","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/RikardFahlstrom/padel-page","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RikardFahlstrom%2Fpadel-page","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RikardFahlstrom%2Fpadel-page/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RikardFahlstrom%2Fpadel-page/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RikardFahlstrom%2Fpadel-page/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RikardFahlstrom","download_url":"https://codeload.github.com/RikardFahlstrom/padel-page/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RikardFahlstrom%2Fpadel-page/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31413269,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-04T20:09:54.854Z","status":"ssl_error","status_checked_at":"2026-04-04T20:09:44.350Z","response_time":60,"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":["docker","dynamodb","flask","nginx","nginx-proxy","python","rollbar"],"created_at":"2024-11-09T14:23:36.220Z","updated_at":"2026-04-04T20:32:37.545Z","avatar_url":"https://github.com/RikardFahlstrom.png","language":"CSS","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Padel Planner\n*Add upcoming slots and let players add themselves to suitable slots for easier scheduling, add stats afterwards!*\n\n---\n\n![Docker](https://img.shields.io/badge/docker-%230db7ed.svg?style=for-the-badge\u0026logo=docker\u0026logoColor=white)\n![Flask](https://img.shields.io/badge/flask-%23000.svg?style=for-the-badge\u0026logo=flask\u0026logoColor=white)\n![Nginx](https://img.shields.io/badge/nginx-%23009639.svg?style=for-the-badge\u0026logo=nginx\u0026logoColor=white)\n![Visual Studio](https://img.shields.io/badge/Visual%20Studio-5C2D91.svg?style=for-the-badge\u0026logo=visual-studio\u0026logoColor=white)\n\n## Installation\nClone the repository and add the following `.env` file to the root directory:\n\n\n```bash\nDEV_ENVIRONMENT='development' or 'production'\nROLLBAR_ACCESS_TOKEN='123abc'\nSECRET_KEY='123cba'\nSQLALCHEMY_DATABASE_URI='sqlite:///db/project.db'\nSQLALCHEMY_ECHO=True\n```\n\n## \u003ca name=\"title1\"\u003e\u003c/a\u003e Deploy webpage\nChange to the directory containing the Dockerfile and run:\n```bash\nsudo docker build -t flask/padel-planner .\n```\n```bash\nsudo docker run -d -p 8003:8000 --restart unless-stopped --mount type=bind,source=\"$(pwd)/db\",target=\"/app/db\" --name padel-planner-prod flask/padel-planner\n```\nMake sure to give the `/db` folder and its content read-write access by running `chmod -R 777 db/`.\n\n## Deploy nginx and certbot\n\nClone this repository and follow instructions\nhttps://github.com/wmnnd/nginx-certbot\n\nSince I run the nginx-certbot container on the same host as the `flask/padel planner` container, I need to update the\nnginx config file `data/nginx/app.conf` to redirect https to the container port on the server `\u003cserver-ip\u003e:8003`.\n\n## Setup development environment\n\nGet a ready-to-use environment by opening the project as a [development container in VS Code](https://code.visualstudio.com/docs/devcontainers/containers).\n\nOnce the development container is opened, change directory to `src/padel-page` and run `python application.py` to run the Flask application.\n\n## Add some basic data to the SQLite database\nChange directory to `padel-page/src/padel-page/db` and run below scripts\n\nAdd courts specific to Uppsala\n```bash\nsqlite3 project.db \"insert into arenas (name) values ('UTK'), ('Evry Padel Fyrislund'), ('Evry Padel Librobäck'), ('WAP Uppsala'), ('Uppsala Padel World'), ('City Padel: Uppsala'), ('USIF Arena'), ('-- select arena --');\"\n```\nAdd default leagues\n```bash\nsqlite3 project.db \"insert into leagues (name) values ('average-joes'), ('justice-league'), ('too-poor-to-golf'), ('best-of-the-rest'), ('call-of-duty'), ('-- select league --');\"\n```\nAdd default players\n```bash\nsqlite3 project.db \"insert into users (username) values ('zbackup-leonardo'), ('zbackup-raphael'), ('zbackup-donatello'), ('zbackup-michelangelo');\"\n```\nAdd some previous and upcoming games\n```bash\nsqlite3 project.db \"\"\"\n    insert into games\n        (date, start_time, end_time, arena_id, league_id)\n    values\n        ('2021-05-01', '18:00:00', '20:00:00', '1', '2'),\n        ('2023-06-10', '18:30:00', '20:30:00', '4', '1'),\n        ('2022-06-11', '19:00:00', '22:00:00', '2', '2'),\n        ('2022-11-01', '18:00:00', '20:00:00', '7', '4'),\n        ('2023-01-22', '20:00:00', '22:15:00', '7', '4'),\n        ('2023-06-04', '18:00:00', '20:00:00', '2', '5'),\n        ('2023-11-10', '18:00:00', '20:00:00', '2', '5')\n    ;\"\"\"\n```\nAdd players to previous and upcoming games\n```bash\nsqlite3 project.db \"\"\"\n    insert into players\n        (game_id, player_id)\n    values\n        (1, 1),\n        (1, 2),\n        (1, 3),\n        (1, 4),\n        (2, 1),\n        (2, 2),\n        (2, 3),\n        (2, 4),\n        (3, 1),\n        (3, 2),\n        (3, 3),\n        (3, 4),\n        (4, 1),\n        (4, 2),\n        (4, 3),\n        (4, 4),\n        (5, 1),\n        (5, 2),\n        (5, 3),\n        (5, 4),\n        (6, 4),\n        (6, 3),\n        (6, 2),\n        (6, 1),\n        (7, 1),\n        (7, 2),\n        (7, 3),\n        (7, 4)\n    ;\"\"\"\n```\n\n:tennis: :calendar: :bar_chart:\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frikardfahlstrom%2Fpadel-page","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frikardfahlstrom%2Fpadel-page","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frikardfahlstrom%2Fpadel-page/lists"}