11 Commits

Author SHA1 Message Date
36f2999cc9 chore(changelog): update unreleased changelog
All checks were successful
Auto Changelog & Release / detect-version-change (push) Successful in 5s
Auto Changelog & Release / release (push) Has been skipped
Auto Changelog & Release / changelog-only (push) Successful in 7s
Build and upload Docker nightly image / build-and-push (push) Successful in 2m24s
2025-05-11 07:04:45 +00:00
7ea8e26660 chore(readme): update image repository URL
All checks were successful
Auto Changelog & Release / detect-version-change (push) Successful in 4s
Auto Changelog & Release / release (push) Has been skipped
Auto Changelog & Release / changelog-only (push) Successful in 8s
Build and upload Docker nightly image / build-and-push (push) Successful in 45s
- Updates the Docker image repository URL for the proxy service
- Chagnes some text in the README file
2025-05-11 09:04:03 +02:00
5ba2ea1233 chore(changelog): update unreleased changelog 2025-05-10 23:34:40 +00:00
573fcf0e65 docs(readme): enhance documentation with usage and features
All checks were successful
Auto Changelog & Release / detect-version-change (push) Successful in 5s
Auto Changelog & Release / changelog-only (push) Successful in 8s
Auto Changelog & Release / release (push) Has been skipped
Build and upload Docker nightly image / build-and-push (push) Successful in 45s
- Add detailed description of the proxy's purpose and features
- Include usage instructions for Docker and Docker Compose
- Document environment variables and file structure
- Provide licensing information and relevant links
2025-05-11 01:34:24 +02:00
0dc8764cc5 chore(changelog): update unreleased changelog 2025-05-10 23:25:07 +00:00
787bcdc1a2 chore(workflows): rename build-docker.yml to build-nightly.yml
All checks were successful
Auto Changelog & Release / detect-version-change (push) Successful in 4s
Auto Changelog & Release / release (push) Has been skipped
Auto Changelog & Release / changelog-only (push) Successful in 8s
Build and upload Docker nightly image / build-and-push (push) Successful in 46s
- Updates workflow file name to reflect nightly build process
- Ensures better alignment with intended functionality
2025-05-11 01:24:52 +02:00
19088219cb chore(changelog): update unreleased changelog 2025-05-10 23:24:13 +00:00
ec18f7b4e3 refactor(dockerfile): update runtime base image to alpine:latest
All checks were successful
Auto Changelog & Release / detect-version-change (push) Successful in 5s
Auto Changelog & Release / release (push) Has been skipped
Auto Changelog & Release / changelog-only (push) Successful in 8s
Build and upload Docker nightly image / build-and-push (push) Successful in 47s
- Switches the runtime base image from denoland/deno:alpine to alpine:latest
  for a more minimal and customizable environment.
- Adds curl installation for optional health checks in containers.
2025-05-11 01:23:57 +02:00
0d872a5acc chore(changelog): update changelog for v0.1.1
All checks were successful
Build and upload Docker release image / upload-assets (release) Successful in 50s
2025-05-10 23:17:09 +00:00
a80ad6927e chore(version): bump version to 0.1.1
All checks were successful
Auto Changelog & Release / detect-version-change (push) Successful in 5s
Auto Changelog & Release / changelog-only (push) Has been skipped
Auto Changelog & Release / release (push) Successful in 10s
Build and upload Docker nightly image / build-and-push (push) Successful in 47s
2025-05-11 01:16:51 +02:00
f931e876f9 chore(workflows): update Docker image repository path
- Change Docker image repository from `simdev` to `maxp`
- Aligns image labels with the new repository location
2025-05-11 01:16:50 +02:00
6 changed files with 106 additions and 6 deletions

View File

@@ -43,7 +43,7 @@ jobs:
CREATED=$(date -u +%Y-%m-%dT%H:%M:%SZ) CREATED=$(date -u +%Y-%m-%dT%H:%M:%SZ)
VERSION_TAG=nightly-$(date +%Y%m%d) VERSION_TAG=nightly-$(date +%Y%m%d)
docker buildx build \ docker buildx build \
--tag git.0xmax42.io/simdev/lt-auth-proxy:nightly \ --tag git.0xmax42.io/maxp/lt-auth-proxy:nightly \
--platform linux/amd64,linux/arm64 \ --platform linux/amd64,linux/arm64 \
--label org.opencontainers.image.description="Lightweight LanguageTool Auth Proxy" \ --label org.opencontainers.image.description="Lightweight LanguageTool Auth Proxy" \
--label org.opencontainers.image.documentation="https://git.0xmax42.io/maxp/lt-auth-proxy" \ --label org.opencontainers.image.documentation="https://git.0xmax42.io/maxp/lt-auth-proxy" \

View File

@@ -63,8 +63,8 @@ jobs:
- name: Build Docker Image - name: Build Docker Image
run: | run: |
docker buildx build \ docker buildx build \
--tag git.0xmax42.io/simdev/lt-auth-proxy:${{ steps.version.outputs.VERSION_STRIPPED }} \ --tag git.0xmax42.io/maxp/lt-auth-proxy:${{ steps.version.outputs.VERSION_STRIPPED }} \
--tag git.0xmax42.io/simdev/lt-auth-proxy:latest \ --tag git.0xmax42.io/maxp/lt-auth-proxy:latest \
--label org.opencontainers.image.description="Lightweight LanguageTool Auth Proxy" \ --label org.opencontainers.image.description="Lightweight LanguageTool Auth Proxy" \
--label org.opencontainers.image.documentation="https://git.0xmax42.io/maxp/lt-auth-proxy" \ --label org.opencontainers.image.documentation="https://git.0xmax42.io/maxp/lt-auth-proxy" \
--label org.opencontainers.image.authors="0xMax42 <mail@0xmax42.io>" \ --label org.opencontainers.image.authors="0xMax42 <mail@0xmax42.io>" \

View File

@@ -2,6 +2,27 @@
All notable changes to this project will be documented in this file. All notable changes to this project will be documented in this file.
## [unreleased]
### 🚜 Refactor
- *(dockerfile)* Update runtime base image to alpine:latest - ([ec18f7b](https://git.0xmax42.io/maxp/lt-auth-proxy/commit/ec18f7b4e39bbfa88ba23ef3fdf825917ac5303b))
### 📚 Documentation
- *(readme)* Enhance documentation with usage and features - ([573fcf0](https://git.0xmax42.io/maxp/lt-auth-proxy/commit/573fcf0e65b3446b7efdce6b1695722c9d757410))
### ⚙️ Miscellaneous Tasks
- *(readme)* Update image repository URL - ([7ea8e26](https://git.0xmax42.io/maxp/lt-auth-proxy/commit/7ea8e26660b9c29ead8f5597647a96c27cc9dcb5))
- *(workflows)* Rename build-docker.yml to build-nightly.yml - ([787bcdc](https://git.0xmax42.io/maxp/lt-auth-proxy/commit/787bcdc1a20e85699b810082895d2a461216c9cf))
## [0.1.1](https://git.0xmax42.io/maxp/lt-auth-proxy/compare/v0.1.0..v0.1.1) - 2025-05-10
### ⚙️ Miscellaneous Tasks
- *(workflows)* Update Docker image repository path - ([f931e87](https://git.0xmax42.io/maxp/lt-auth-proxy/commit/f931e876f9d99c40a29f9aca8626af22b9f0772e))
## [0.1.0] - 2025-05-10 ## [0.1.0] - 2025-05-10
### 🚀 Features ### 🚀 Features

View File

@@ -14,7 +14,7 @@ COPY import_map.json ./import_map.json
RUN deno task compile RUN deno task compile
# -------- Stage 2: Minimal runtime environment -------- # -------- Stage 2: Minimal runtime environment --------
FROM denoland/deno:alpine FROM alpine:latest
# Optional: Install curl for container-level health checks (not needed for production-only binaries) # Optional: Install curl for container-level health checks (not needed for production-only binaries)
RUN apk add --no-cache curl RUN apk add --no-cache curl

View File

@@ -1,3 +1,82 @@
# lt-auth-proxy # lt-auth-proxy
Language Tool authentication proxy A lightweight, production-ready reverse proxy for [LanguageTool](https://languagetool.org) with API key authentication.
This service acts as a transparent gateway that verifies an `apiKey` before forwarding requests to a running LanguageTool server instance. It is fully self-contained, built in Deno, and distributed as a minimal multi-architecture Docker image.
---
## ✨ Features
* 🔐 **API key authentication** via query or form body
* 📡 **Transparent proxying** to any LanguageTool backend
* 🐳 **Minimal Docker image (\~93 MB)**
* 🧱 **Statically compiled** Deno binary
* 🧪 **Unit tested** middleware and proxy logic
* 🛠️ Compatible with regular LT clients
---
## 🚀 Usage
You can run the proxy via Docker:
```bash
docker run -p 8011:8011 \
-e API_KEYS="demo-key,another-key" \
-e LT_SERVER_HOST=lt-server \
-e LT_SERVER_PORT=8010 \
git.0xmax42.io/simdev/lt-auth-proxy:latest
```
---
## 🧪 Supported Environment Variables
| Variable | Required | Default | Description |
| ---------------- | -------- | ----------- | ---------------------------------------- |
| `API_KEYS` | ✅ yes | – | Comma-separated list of valid API tokens |
| `PROXY_HOST` | ❌ no | `0.0.0.0` | Host/IP address to bind the proxy to |
| `PROXY_PORT` | ❌ no | `8011` | Port the proxy listens on |
| `LT_SERVER_HOST` | ❌ no | `localhost` | Hostname of the LanguageTool backend |
| `LT_SERVER_PORT` | ❌ no | `8010` | Port of the LanguageTool backend |
---
## 📁 File Structure
```
src/
├── main.ts # Entry point, sets up the HTTP kernel
├── env.ts # Lazy-loaded environment access
├── ltProxyAuth.ts # Middleware to check the apiKey
├── ltProxyHandler.ts# Handler to forward the request to LT
```
---
## 🐳 Docker Compose Example
```yaml
services:
lt-server:
image: languagetool/languagetool:latest
ports:
- "8010:8010"
proxy:
image: git.0xmax42.io/maxp/lt-auth-proxy:latest
ports:
- "8011:8011"
environment:
- API_KEYS=demo-key
- LT_SERVER_HOST=lt-server
- LT_SERVER_PORT=8010
```
---
## 📖 License
MIT © 0xMax42
[https://git.0xmax42.io/maxp/lt-auth-proxy](https://git.0xmax42.io/maxp/lt-auth-proxy)

View File

@@ -1 +1 @@
0.1.0 0.1.1