Commit graph

15 commits

Author SHA1 Message Date
Albert Armea
00544d978e
Fix README typo 2026-03-21 20:02:04 -04:00
Albert Armea
0cbd05c64f
Add motivation to README 2026-03-21 19:59:52 -04:00
Albert Armea
483617e41a Move geo_rules.yml into its own directory
This way, Docker still passes through changes made by text editors
2026-03-21 22:26:55 +00:00
Albert Armea
50275ae116 Fix geofencing 2026-03-21 22:15:40 +00:00
Albert Armea
45181f9f54 Fix Forgejo data paths 2026-03-21 21:52:14 +00:00
Albert Armea
4fcb4d78f1 Fix certbot initialization 2026-03-21 21:51:14 +00:00
Albert Armea
c9d9758b1a part 2 of template substitution fix 2026-03-21 20:11:29 +00:00
Albert Armea
e77090478b Fix nginx map size 2026-03-21 20:10:54 +00:00
Albert Armea
6e6c958588 Fix nginx first run without maxmind db 2026-03-21 20:10:27 +00:00
Albert Armea
76effee03f Make geoblock watcher render in repos 2026-03-21 20:08:28 +00:00
Albert Armea
e7036d99a8 Fix nginx build 2026-03-21 20:07:31 +00:00
Albert Armea
c515981236 Fix nginx template substitution 2026-03-21 20:06:57 +00:00
Albert Armea
888f6bde0d Never check in the certs 2026-03-21 18:52:34 +00:00
Albert Armea
1e2187d297 Fix initial script run 2026-03-21 18:52:19 +00:00
Albert Armea
cf99cd50f2 Initial commit
Change written by Claude Sonnet 4.6:

I need to set up a Git hosting service for personal projects where certain repositories need to be blocked using the locale corresponding to the user’s IP address.

Here are my constraints:
*   The entire system will be running on a single VPS instance. I should be able to `docker compose up -d` the whole thing.
*   For each repository that this feature is enabled, I need to be able to set the blocked locales down to the state level, along with a custom HTTP status code and response body.
*   You may assume that the IP address of the request is where it actually came from — for this exercise, if the user uses a VPN to bypass the restriction, that is on them.
*   To simplify a reverse proxy setup, you may assume that all Git operations will happen over HTTPS. I will firewall off SSH access.
*    I will be using Let's Encrypt for HTTPS.

Some suggestions from prior research:
*   nginx seems like a reasonable reverse proxy that supports all of the requirements, but you may use a different one if it is simpler to implement or maintain.
*   I can obtain a MaxMind API key to get a geo-IP lookup table. If you use this, you will need to add a service that automatically retrieves the table at a reasonable frequency.
*   Forgejo seems like a reasonable, lightweight Git service, but you may use a different one if you’re aware of one that actually supports these requirements out of the box.

Write me a production-ready `docker-compose.yml` and supporting scripts or configuration scaffolding for me to implement this.
2026-03-21 18:34:50 +00:00