blumeops/fly/Dockerfile
Erich Blume e198c70af6 Update tooling dependencies (March 2026)
Prek hooks: trufflehog v3.94.0, ruff v0.15.7, shfmt v3.13.0-1,
ansible-lint>=26.3.0, ansible-core>=2.18.
Fly.io proxy: nginx 1.29.6-alpine, Alloy v1.14.1.
Forgejo workflows: actions/checkout v4.3.1 → v6.0.2 (SHA-pinned).
Mise tasks: tighten Python lower bounds (rich>=14, typer>=0.24,
httpx>=0.28.1, pyyaml>=6.0.2).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-24 08:10:48 -07:00

33 lines
1.1 KiB
Docker

FROM nginx:1.29.6-alpine
# Copy tailscale binaries from official image
COPY --from=docker.io/tailscale/tailscale:stable \
/usr/local/bin/tailscaled /usr/local/bin/tailscaled
COPY --from=docker.io/tailscale/tailscale:stable \
/usr/local/bin/tailscale /usr/local/bin/tailscale
RUN mkdir -p /var/run/tailscale /var/lib/tailscale \
&& apk add --no-cache iptables ip6tables \
&& apk add --no-cache libc6-compat \
&& apk add --no-cache fail2ban \
&& rm -f /etc/fail2ban/jail.d/alpine-ssh.conf
# Copy Alloy binary from official image (Ubuntu-based, needs libc6-compat)
COPY --from=docker.io/grafana/alloy:v1.14.1 \
/bin/alloy /usr/local/bin/alloy
RUN mkdir -p /var/log/nginx /etc/alloy /tmp/alloy-data
COPY fail2ban/filter.d/forge-login.conf /etc/fail2ban/filter.d/forge-login.conf
COPY fail2ban/jail.d/forge.conf /etc/fail2ban/jail.d/forge.conf
COPY fail2ban/action.d/nginx-deny.conf /etc/fail2ban/action.d/nginx-deny.conf
COPY nginx.conf /etc/nginx/nginx.conf
COPY error.html /usr/share/nginx/html/error.html
COPY alloy.river /etc/alloy/config.alloy
COPY start.sh /start.sh
RUN chmod +x /start.sh
EXPOSE 8080
CMD ["/start.sh"]