Something went wrong. Try again.
[READ-ONLY] Mirror of https://github.com/Aquaticat/Monochromatic. TypeScript and Rust monorepo: Claude Code and Pi coding-agent plugins, a m
Something went wrong. Try again.
3.1 kB · 90 lines
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091# Minimal repology-updater environment for package index generation.# Fetches only the repos we care about, not the full production set.## Build (with GitHub token for authenticated clones):# podman build --secret id=github_token,env=GITHUB_TOKEN \# -t repology-updater -f generator/Containerfile generator/## Run (fetches repos, auto-inits on first run):# podman run --rm -v repology-state:/state -v repology-parsed:/parsed \# -v repology-pgdata:/var/lib/pgsql/data repology-updater \# --fetch --fetch --parse --database## Extract data:# podman run --rm -v repology-state:/state -v repology-parsed:/parsed \# -v repology-pgdata:/var/lib/pgsql/data repology-updater --extract
FROM registry.fedoraproject.org/fedora:latest
# PostgreSQL 18, Python 3.14, libversion build depsRUN dnf install -y --setopt=install_weak_deps=False \ postgresql-server \ postgresql-server-devel \ postgresql-contrib \ python3 \ python3-pip \ python3-devel \ gcc \ gcc-c++ \ redhat-rpm-config \ cmake \ pkg-config \ git \ rsync \ rpm2cpio \ cpio \ yajl-devel \ libxml2-devel \ libxslt-devel \ python3-rpm \ && dnf clean all
# Configure git to use GitHub token when available (via build secret).# The credential helper writes the token into the extraheader so all# github.com clones are authenticated, avoiding rate limits.RUN --mount=type=secret,id=github_token \ if [ -f /run/secrets/github_token ] && [ -s /run/secrets/github_token ]; then \ TOKEN=$(cat /run/secrets/github_token) \ && git config --global url."https://${TOKEN}@github.com/".insteadOf "https://github.com/" ; \ fi
# Build and install libversion + pg extensionRUN git clone --depth 1 https://github.com/repology/libversion.git /tmp/libversion \ && cd /tmp/libversion \ && cmake -DCMAKE_INSTALL_PREFIX=/usr . \ && make -j"$(nproc)" \ && make install \ && ldconfig \ && rm -rf /tmp/libversion
RUN git clone --depth 1 https://github.com/repology/postgresql-libversion.git /tmp/pg-libversion \ && cd /tmp/pg-libversion \ && make -j"$(nproc)" \ && make install \ && rm -rf /tmp/pg-libversion
# Clone repology-updater and rulesWORKDIR /repologyRUN git clone --depth 1 https://github.com/repology/repology-updater.git . \ && git clone --depth 1 https://github.com/repology/repology-rules.git rules.d
# Remove the credential helper so the token is not baked into the imageRUN git config --global --unset-all url."https://github.com/".insteadOf 2>/dev/null || true
# Python dependenciesRUN pip install --no-cache-dir --break-system-packages -r requirements.txt
# Custom config scoped to our target reposCOPY repology.conf /repology/repology.conf
# Extraction SQLCOPY extract.sql /repology/extract.sql
# Entrypoint scriptCOPY entrypoint.sh /repology/entrypoint.shRUN chmod +x /repology/entrypoint.sh
# Persistent volumes for incremental updatesVOLUME ["/state", "/parsed"]
ENTRYPOINT ["/repology/entrypoint.sh"]