Commit graph

9 commits

Author SHA1 Message Date
81f13f789b
revert: remove custom base image dependency from main Dockerfile
Reverted k8s/Dockerfile back to using official hexpm/elixir and debian
images directly instead of custom gmcintire/towerops-base images.

This restores the original Dockerfile behavior where all dependencies
are installed during each build. The base image work in k8s/base-image/
remains available but is not used by the main application build.
2026-01-25 11:12:37 -06:00
564caed3e5
refactor: rename base images to gmcintire/towerops-base
Changed image naming scheme from separate builder/runtime images to a
single image name with different tags:

- docker.io/gmcintire/towerops-base:builder
- docker.io/gmcintire/towerops-base:runtime
- docker.io/gmcintire/towerops-base:latest (alias for runtime)

This simplifies the naming and makes it clearer that both images are
part of the same towerops-base image family.

Changes:
- build.sh: Use IMAGE_NAME with BUILDER_TAG/RUNTIME_TAG
- Makefile: Update all targets to use new naming
- k8s/Dockerfile: Point to gmcintire/towerops-base:builder and :runtime
2026-01-25 09:33:42 -06:00
edd64479df
feat: create builder and runtime base images for faster deploys
Instead of installing system packages and tools on every deploy, we now
have two base images that pre-bake all the slow setup steps.

Base Images Created:
1. elixir-builder:latest - Builder stage base
   - hexpm/elixir with build-essential and git pre-installed
   - hex and rebar pre-installed
   - Saves ~40 seconds per deploy

2. debian-runtime:latest - Runtime stage base
   - Debian with all runtime packages pre-installed
   - Locale pre-configured (en_US.UTF-8)
   - /app directory pre-created
   - Saves ~60 seconds per deploy

Main Dockerfile Changes:
- Use elixir-builder:latest instead of hexpm/elixir
- Use debian-runtime:latest instead of debian:trixie-slim
- Remove apt-get install steps (now in base images)
- Remove hex/rebar install (now in builder base)
- Remove locale setup (now in runtime base)

Build System:
- build.sh builds both images with podman/docker auto-detect
- Pushes to both GitLab registry and Docker Hub
- Makefile targets for build/test/push/clean

Total Time Saved Per Deploy: ~100 seconds (1m40s)

Benefits:
- Faster CI/CD builds (no repeated apt-get install)
- Faster local development builds
- Consistent build environment across all deploys
- Security updates centralized in base image rebuilds
2026-01-25 09:29:22 -06:00
ba5464332b
fix: use system ping command instead of raw ICMP sockets
- Rewrote Ping module to use system ping binary instead of raw ICMP
  sockets which required CAP_NET_RAW privileges
- Added iputils-ping package to Docker images for production
- Added proper IP address validation before executing ping command
- Updated tests to account for 1 second minimum timeout of system ping
- System ping binary is setuid root and works without elevated privileges
2026-01-21 11:15:59 -06:00
b8b3c5dce0
add parallel build 2026-01-19 14:17:05 -06:00
d7481dc0fd
Silence debconf warnings in Docker builds
Set DEBIAN_FRONTEND=noninteractive for all apt-get operations
to prevent interactive frontend warnings in build logs
2026-01-03 16:00:54 -06:00
1ea4496e95
Add BuildKit cache mounts to speed up Docker builds
- Cache Hex packages across builds
- Cache Mix archives across builds
- Cache npm packages for asset tooling
- Speeds up dependency installation significantly
2026-01-03 15:55:24 -06:00
570c6d03b3
Dockerfile improvements 2026-01-03 15:38:14 -06:00
92c5160f6e
Add Kubernetes deployment manifests for towerops.net 2026-01-02 14:38:52 -06:00