{"id":21413125,"url":"https://github.com/rixrix/dangx-project","last_synced_at":"2025-03-16T18:22:56.002Z","repository":{"id":66584614,"uuid":"98534069","full_name":"rixrix/dangx-project","owner":"rixrix","description":" DangX: Docker + Alpine + NodeJS - nGinX Reverse Proxy Server ","archived":false,"fork":false,"pushed_at":"2017-08-15T08:26:12.000Z","size":270,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-23T05:15:26.691Z","etag":null,"topics":["alpine-linux","api","devops","dnsmasq","docker","linux","microservices","nginx","nodejs","proxy","reverse-proxy","windows-10"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/rixrix.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-07-27T12:38:01.000Z","updated_at":"2022-05-02T22:16:01.000Z","dependencies_parsed_at":null,"dependency_job_id":"7466984c-2dac-448b-85ee-1b6c10a8d911","html_url":"https://github.com/rixrix/dangx-project","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rixrix%2Fdangx-project","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rixrix%2Fdangx-project/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rixrix%2Fdangx-project/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rixrix%2Fdangx-project/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rixrix","download_url":"https://codeload.github.com/rixrix/dangx-project/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243910762,"owners_count":20367544,"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":["alpine-linux","api","devops","dnsmasq","docker","linux","microservices","nginx","nodejs","proxy","reverse-proxy","windows-10"],"created_at":"2024-11-22T18:16:54.815Z","updated_at":"2025-03-16T18:22:55.996Z","avatar_url":"https://github.com/rixrix.png","language":"JavaScript","readme":"# Dangx Project\n\n![Simple Diagram](docs/diagram.png)\n\nThis is an attempt to build a microservices architecture: API driven, lightweight on infrastructure (Alpine Linux), loosely coupled services. See ideas from [1], [2]\n\n# Tech Stack\n\n* Alpine Linux\n* NodeJS\n* Nginx\n* Dnsmasq\n* Docker\n\n# Commands / HowTo\n\n* 1. For fresh project, create the special network\n  * `./scripts/docker-new-network.sh`\n* 2. Build the containers\n  * `./scripts/docker-compose-up.sh`\n* 3. Destroy the containers, excluding network and images\n  * `./scripts/docker-compose-down.sh`\n* 4. Restart the containers\n  * `./scripts/docker-compose-restart.sh`\n\n# Folder Structure\n\n```\n./\n    docker/\n        +- all Docker related files\n    scipts/\n        +- compose scripts, new network, etc\n    www-api/\n        +- API source code\n    www-public/\n        +- Landing/static page\n```\n\n# Todo\n\nThe list below requires a massive amount of time but definitely doable.\n\n* Deploy to AWS\n* Build infra with Terraform\n* Use registry like Consul, etc\n* Multi-cloud deployment eg. AWS, Google Cloud, Azure\n* Use CI\n* Others, file an issue\n\n# Services\n\n* www-dangxproject\n  * Project landing page, mostly static assets\n  * Info\n    * URL: http://dangxproject.dev\n    * Port: 3000, Expose: 80\n* www-api\n  * NodeJS-based API\n  * Info\n    * URL: http://api.dangxproject.dev\n    * Port: 3001, Expose: 80\n\n# Notes\n\n* Dnsmasq\n  * Configured to only return queries for any host under \"dev\" eg: xxx.dev, api.dangxproject.dev on 127.0.0.1 IP address\n  * command section in docker-compose.dnsmasq.yml and its manpage\n* Docker vEthernet on Windows 10\n  * Attach the following entries below to your Docker vEthernet IPv4 adapter:\n    * DNS Server: 127.0.0.1\n    * DNS Suffix: dev\n* Tested on Windows 10\n  * Windows 10 Pro Insider Release Build: 16251.rs3_release\n  * Docker Server Version: 17.06.0-ce\n  * Kernel Version: 4.9.36-moby\n  * Dell XPS 13 9343\n\n# References\n\n* [1] IBM, Learning Microservices Architecture with Bluemix and Docker\n  * http://blog.ibmjstart.net/2015/07/23/learning-microservices-architecture-bluemix-docker-part-1/\n* [2] Improving dev environments: All the HTTP things\n  * https://adrianperez.org/improving-dev-environments-all-the-http-things/\n* Docker 2-way linking\n  * https://medium.com/@yani/two-way-link-with-docker-compose-8e774887be41\n* Docker Nginx Proxy: https://github.com/jwilder/nginx-proxy\n* Docker Dnsmasq\n  * https://hub.docker.com/r/andyshinn/dnsmasq/\n  * http://www.thekelleys.org.uk/dnsmasq/doc.html\n  * http://www.thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html\n* https://jqnotes.blogspot.co.nz/2012/08/configure-windows-7-to-support-dnsmasq.html\n* https://stackoverflow.com/questions/330395/dns-problem-nslookup-works-ping-doesnt\n* https://www.windowscentral.com/how-change-your-pcs-dns-settings-windows-10\n* https://serverfault.com/questions/391914/is-there-a-way-to-use-a-specific-dns-for-a-specific-domain\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frixrix%2Fdangx-project","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frixrix%2Fdangx-project","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frixrix%2Fdangx-project/lists"}