Files
KNELProductionContainers/CloudronPackages/Rathole/Dockerfile
ReachableCEO e32e9288d1 feat(rathole,apisix): complete Rathole and APISIX Cloudron packages
- Fix Rathole download URL to use .zip format instead of .tar.gz
- Complete APISIX package using official apache/apisix:3.8.0-debian base image
- Add cloudron user creation for APISIX compatibility
- Both packages build successfully and follow KNELCloudron- naming convention
- Rathole: reverse proxy tunnel with proper binary download
- APISIX: API gateway with official Docker image base
2025-10-17 10:19:59 -05:00

41 lines
1.1 KiB
Docker

FROM cloudron/base:5.0.0
ARG RATHOLE_VERSION=v0.5.0
ARG ARCH=x86_64-unknown-linux-gnu
USER root
RUN apt-get update \
&& apt-get install -y --no-install-recommends curl ca-certificates unzip python3 \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app/pkg
# Download Rathole release binary (adjust version/arch via build args)
RUN set -eux; \
url="https://github.com/rathole-org/rathole/releases/download/${RATHOLE_VERSION}/rathole-${ARCH}.zip"; \
echo "Fetching ${url}"; \
curl -fsSL "$url" -o rathole.zip; \
unzip rathole.zip; \
rm rathole.zip; \
chmod +x rathole; \
chown cloudron:cloudron rathole
# Start script
COPY start.sh /app/pkg/start.sh
RUN chmod +x /app/pkg/start.sh && chown cloudron:cloudron /app/pkg/start.sh
WORKDIR /app/code
RUN mkdir -p /app/data && chown -R cloudron:cloudron /app/data
USER cloudron
ENV APP_PORT=3000 \
RATHOLE_CONFIG_PATH=/app/data/rathole.toml
EXPOSE 3000 2333
HEALTHCHECK --interval=30s --timeout=5s --start-period=20s --retries=3 \
CMD curl -fsS http://127.0.0.1:${APP_PORT}/ || exit 1
CMD ["/app/pkg/start.sh"]