{"id":19766198,"url":"https://github.com/akaliutau/randomizer","last_synced_at":"2026-05-01T06:32:58.724Z","repository":{"id":214776644,"uuid":"737274182","full_name":"akaliutau/randomizer","owner":"akaliutau","description":"A docker image with simple Flask application to test  Kubernetes cluster","archived":false,"fork":false,"pushed_at":"2023-12-31T13:37:45.000Z","size":8,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-29T15:11:56.570Z","etag":null,"topics":["docker-hub","dockerized-app","flask","kubernetes-cluster","python3"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/akaliutau.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":"2023-12-30T12:42:04.000Z","updated_at":"2023-12-30T15:59:22.000Z","dependencies_parsed_at":"2023-12-30T17:56:23.760Z","dependency_job_id":"832a7829-980c-406d-9faf-040ff9bbd120","html_url":"https://github.com/akaliutau/randomizer","commit_stats":null,"previous_names":["akaliutau/randomizer"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/akaliutau/randomizer","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/akaliutau%2Frandomizer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/akaliutau%2Frandomizer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/akaliutau%2Frandomizer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/akaliutau%2Frandomizer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/akaliutau","download_url":"https://codeload.github.com/akaliutau/randomizer/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/akaliutau%2Frandomizer/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32487426,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"online","status_checked_at":"2026-05-01T02:00:05.856Z","response_time":64,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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-hub","dockerized-app","flask","kubernetes-cluster","python3"],"created_at":"2024-11-12T04:23:02.107Z","updated_at":"2026-05-01T06:32:58.708Z","avatar_url":"https://github.com/akaliutau.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# About\nA docker image with simple Flask application to test Kubernetes cluster. \n\nFor example, one can simulate network failure scenarios (via toggling liveness probe) or app failure (using readiness \nprobe programmable logic). The app contains in-built version and generates a unique UUID on startup\n\nBusiness logic is simple - the main endpoint returns random number  \n\n# Installation\n\n\n```shell\npython3 -m venv venv\nsource ./venv/bin/activate\npip install -r requirements.txt\n```\n\n# Running\n\nTo start local server\n```shell\n# export PORT=8080 - optional\npython3 app.py\n```\n\n(default port is 8080, since 80 is usually taken by other processes)\n\n# Building image\n\nTest and dev built:\n\n```shell\nsudo docker build -t randomizer:1.0 .\nsudo docker run randomizer:1.0\n```\nNote, docker runs images in isolation mode by default and hence you cannot connect to localhost:8080. Use mapping instead:\n\n```shell\ndocker run -d -p 8080:8080 randomizer:1.0\ndocker kill \u003ccontainer_id\u003e\n```\n\nProduction built:\n\n```shell\ndocker login -u \u003cuser_name\u003e\ndocker tag randomizer:1.0 \u003cuser_name\u003e/randomizer:1.0\ndocker push \u003cuser_name\u003e/randomizer:1.0\n```\n\n# API\n| endpoint            | action                            |   \n|---------------------|-----------------------------------|\n | /                   | returns random number             |\n| /memory-loader?mb=3 | allocates memory buffer in 3 MB   |\n| /toggle-live        | toggles liveness probe            |\n| /toggle-ready       | toggles readiness probe           |\n| /health             | returns 200 OK or 500 Error       |\n| /info               | returns insights about server env |\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fakaliutau%2Frandomizer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fakaliutau%2Frandomizer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fakaliutau%2Frandomizer/lists"}