{"id":31913598,"url":"https://github.com/zhibirc/weather","last_synced_at":"2025-10-13T18:51:22.746Z","repository":{"id":40703120,"uuid":"133831906","full_name":"zhibirc/weather","owner":"zhibirc","description":":books: Educational project.","archived":false,"fork":false,"pushed_at":"2022-12-14T06:17:50.000Z","size":5111,"stargazers_count":1,"open_issues_count":6,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-04-16T17:27:46.302Z","etag":null,"topics":["docker","docker-example","docker-playground","education","learning","weather","weather-app","weather-data"],"latest_commit_sha":null,"homepage":"","language":"HTML","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/zhibirc.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}},"created_at":"2018-05-17T15:18:12.000Z","updated_at":"2023-10-27T20:26:07.000Z","dependencies_parsed_at":"2022-07-29T02:38:18.475Z","dependency_job_id":null,"html_url":"https://github.com/zhibirc/weather","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/zhibirc/weather","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zhibirc%2Fweather","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zhibirc%2Fweather/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zhibirc%2Fweather/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zhibirc%2Fweather/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zhibirc","download_url":"https://codeload.github.com/zhibirc/weather/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zhibirc%2Fweather/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279016623,"owners_count":26085853,"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","status":"online","status_checked_at":"2025-10-13T02:00:06.723Z","response_time":61,"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","docker-example","docker-playground","education","learning","weather","weather-app","weather-data"],"created_at":"2025-10-13T18:49:58.257Z","updated_at":"2025-10-13T18:51:22.737Z","avatar_url":"https://github.com/zhibirc.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# weather \u0026middot; [![GitHub](https://img.shields.io/github/license/mashape/apistatus.svg?style=flat-square)](LICENSE) [![Maintenance](https://img.shields.io/maintenance/yes/2021.svg?style=flat-square)]() [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-blue.svg)]()\n\n![weather](./screenshot.png)\n\n\u003cp align=\"center\"\u003eFull-Stack Web App (consists of a client side and a server part) as a playground for experiments and learning Docker/Docker Compose/NGINX etc.\u003c/p\u003e\n\n## About\n\nApplication called **Weather** has the following capabilities:\n\n- input field for location name, and a submit button in browser UI\n- user can specify some location name for getting weather for and press the button\n- back-end listen for POST HTTP request and validate user input from it\n- back-end communicates with two external services:\n    - [OpenWeather](https://openweathermap.org/) for retrieving weather for particular location\n    - [Pexels](https://www.pexels.com/api/) for retrieving image demonstrated the specific weather state\n- both weather and image metadata return by back-end to the browser\n- client logic parses the given JSON data and render it appropriately\n\n## Containerize\n\nChoose suitable variant from the below and normally the Web UI should be available on **http://localhost:8080/**.\n\n1) One-Command Deployment (_without_ cloning the repo)\n\n```shell\ncurl -L https://github.com/zhibirc/weather/archive/refs/tags/v1.0.tar.gz | tar xz \u0026\u0026 cd weather-1.0 \u0026\u0026 npm start\n```\n\n2) One-Command Deployment (after cloning the repo)\n\n```shell\n# it calls \"docker compose up --build\"\nnpm start\n```\n\n3) Build and setup manually\n\n```shell\n# build and deploy front-end\ndocker build --tag front-end --no-cache ./public\n# build and deploy back-end\ndocker build --tag back-end --no-cache ./server\n# create network to connect both parts\ndocker network create weather-net\n# run server and add to existing network\ndocker run --name back-end --network weather-net -p 8081:8081 -d back-end\n# run front-end and add to existing network\ndocker run --name front-end --network weather-net -p 8080:80 -d front-end\n```\n\nFor _public_ aka _front-end_ part the `nginx.conf` (default NGINX configuration file) is mounted from host system (`./public/nginx.conf`)\nfor simplifying development process. Edit this file if needed and send the `HUP` signal to Docker to reload the NGINX configuration:\n\n```shell\ndocker kill -s HUP \u003ccontainer_name\u003e\n```\n\n## Contributing\n\nI'm grateful to the community for contributing bug fixes and improvements. Read [checklist](./checklist.md) to learn how you can take part in improving.\n\n## License\n\n**weather** is [MIT licensed](./LICENSE)\n\n**favicon** author: \u0026copy; 2020 Twitter, Inc and other contributors (https://github.com/twitter/twemoji) | CC-BY 4.0 (https://creativecommons.org/licenses/by/4.0/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzhibirc%2Fweather","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzhibirc%2Fweather","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzhibirc%2Fweather/lists"}