No description
Find a file
Graham McIntire a796f8a3a9
Add Weather API controller with parameter validation
Implements GET /api/v1/weather/nearby endpoint with comprehensive parameter
validation and error handling. The controller validates required parameters
(lat, lon, radius) and optional parameters (hours, limit) with appropriate
range checking. Integrates with PreparedQueries for efficient database access
and WeatherJSON for response serialization.

Key features:
- Required params: lat (-90 to 90), lon (-180 to 180), radius (0-1000 miles)
- Optional params: hours (1-168, default 6), limit (1-100, default 50)
- Proper error responses via FallbackController (400 for bad requests, 422 for validation)
- Full test coverage (16 tests) including edge cases and error scenarios

Also updates FallbackController to handle {:error, status, message} tuples
and fixes WeatherJSON to support both field name formats (lat/lon and latitude/longitude)
for compatibility with existing tests and actual query results.
2026-03-22 11:27:45 -05:00
.cursor/rules test coverage 2025-06-22 20:38:25 -05:00
.devcontainer update deps 2025-12-30 13:35:11 -06:00
.forgejo/workflows fix: correct Renovate configuration issues 2026-03-03 10:48:48 -06:00
.github/workflows Restore FluxCD auto-deployment via GitOps 2026-02-18 16:15:43 -06:00
assets fix: performance improvements and bug fixes across backend and frontend 2026-03-19 12:41:36 -05:00
config config: disable SSL/TLS for database connections 2026-03-22 11:27:44 -05:00
docs docs: add weather nearby API implementation plan 2026-03-22 11:27:45 -05:00
k8s chore: update aprs.me image to git.mcintire.me/graham/aprs.me:main-1774029416-df6431c [skip ci] 2026-03-20 17:57:39 +00:00
lib Add Weather API controller with parameter validation 2026-03-22 11:27:45 -05:00
priv vendor heroicons 16/solid SVGs to priv 2026-03-15 14:07:56 -05:00
rel Fix Erlang clustering: use IP-based node names with DNS strategy 2026-02-19 16:01:20 -06:00
scripts Remove all VectorGrid references and code 2025-07-28 07:43:44 -05:00
test Add Weather API controller with parameter validation 2026-03-22 11:27:45 -05:00
vendor Display APRS object/item names instead of sender callsign 2026-02-19 09:13:03 -06:00
.credo.exs auto style things 2023-12-17 12:11:57 -06:00
.dialyzer_ignore.exs Replace ip-api.com geolocation with Cloudflare headers 2026-02-19 15:01:49 -06:00
.dockerignore Implement all Docker performance optimizations 2025-07-26 16:12:47 -05:00
.formatter.exs update 2026-02-18 14:14:49 -06:00
.gitignore chore: ignore .worktrees directory for git worktree isolation 2026-03-01 15:01:08 -06:00
.gitmodules add gleam parser to test 2025-08-05 13:18:31 -05:00
.sobelow-skips Add other SSIDs list to map sidebar, fix context/web boundary 2026-02-18 18:15:02 -06:00
.test-commands perf: Optimize test suite for maximum speed 2025-08-01 17:43:39 -05:00
.tool-versions Bump Elixir 1.19.5/OTP 28.3/Debian trixie in Dockerfile and .tool-versions 2026-02-20 10:14:28 -06:00
AGENTS.md cleanup 2026-02-07 10:55:19 -06:00
capture_aprs.py Add mix parse_file task, fix datetime deprecation, update gitignore, fix cleanup worker test 2026-02-18 14:49:14 -06:00
CHANGELOG.md fix: remove invalid empty state from stream container 2025-10-12 12:16:27 -05:00
CLAUDE.md Add Tidewave dev dependency for browser-based debugging 2026-02-18 13:15:03 -06:00
Dockerfile Split Dockerfile build steps for better layer caching 2026-02-20 10:18:48 -06:00
fly.toml fly things 2025-06-13 15:10:29 -05:00
horusec-config.json add horusec to ci 2025-06-15 17:19:26 -05:00
LICENSE Initial commit 2023-01-26 13:19:38 -06:00
mix.exs chore(deps): update dependencies to latest versions 2026-03-15 14:11:17 -05:00
mix.lock chore(deps): update floki 0.38.1, igniter 0.7.6, swoosh 1.23.1 2026-03-19 12:57:07 -05:00
README.md docs: remove K3s deployment section from README 2026-02-25 16:28:29 -06:00
renovate.json chore(config): migrate config renovate.json 2026-03-03 16:58:26 +00:00
security-policy.json docker security 2025-06-15 11:06:24 -05:00
tail_logs.sh update 2026-02-25 16:29:45 -06:00
TODO.md Remove completed items from TODO.md 2026-02-20 09:06:49 -06:00
tsconfig.json typescript 2025-06-18 12:26:13 -05:00

Aprs

Prerequisites

Before setting up the project, ensure you have the following installed:

  • Elixir 1.17+
  • Erlang/OTP
  • PostgreSQL with PostGIS extension

Setup

To start your Phoenix server:

  • Run the complete setup:
    mix setup
    
  • Start Phoenix endpoint with mix phx.server or inside IEx with iex -S mix phx.server

Now you can visit localhost:4000 from your browser.

Ready to run in production? Please check our deployment guides.

Deployment

This application is deployed to a Kubernetes cluster using Flux GitOps. The Kubernetes manifests are in the k8s/ directory and are automatically applied by Flux when changes are pushed to the main branch.

Learn more