Constellation, Spacedust, Slingshot, UFOs: atproto crates and services for microcosm
0

Configure Feed

Select the types of activity you want to include in your feed.

Slingshot docker files (still need testing)

authored by

Bailey Townsend and committed by
Tangled
(Jul 2, 2026, 7:34 PM +0300) e54f6518 e313c9dd

+74
+1
.gitignore
··· 2 2 local/ 3 3 rocks.test 4 4 constellation-data 5 + slingshot-data
+26
docker-compose.yml
··· 26 26 - "0.0.0.0:8765" 27 27 restart: unless-stopped 28 28 29 + slingshot: 30 + build: 31 + context: . 32 + dockerfile: ./slingshot/Dockerfile 33 + container_name: slingshot 34 + environment: 35 + - RUST_LOG=info 36 + ports: 37 + - "8080:8080" # HTTP / XRPC API 38 + - "8766:8765" # prometheus metrics (host 8766 to avoid clashing with constellation's 8765) 39 + # Saves caches directly to a folder on disk 40 + volumes: 41 + - ./slingshot-data:/data 42 + command: 43 + - "--jetstream" 44 + - "us-east-1" 45 + - "--cache-dir" 46 + - "/data" 47 + - "--bind" 48 + - "0.0.0.0:8080" 49 + - "--collect-metrics" 50 + - "--bind-metrics" 51 + - "0.0.0.0:8765" 52 + restart: unless-stopped 53 + 29 54 volumes: 30 55 constellation-data: 56 + slingshot-data:
+47
slingshot/Dockerfile
··· 1 + # Multi-stage build for slingshot. 2 + # 3 + # The build context must be the workspace ROOT (microcosm-rs/) 4 + FROM rust:1.96-bookworm AS builder 5 + 6 + # aws-lc-sys (pulled in via rustls' default aws-lc-rs provider) builds a C 7 + # library with cmake and runs bindgen (needs libclang); reqwest's default-tls 8 + # and jetstream's tungstenite native-tls need OpenSSL headers. 9 + RUN apt-get update && apt-get install -y --no-install-recommends \ 10 + clang \ 11 + libclang-dev \ 12 + build-essential \ 13 + cmake \ 14 + libssl-dev \ 15 + pkg-config \ 16 + && rm -rf /var/lib/apt/lists/* 17 + 18 + WORKDIR /app 19 + COPY . . 20 + 21 + # Cache the cargo registry and target dir across builds. Because the target dir 22 + # lives in a cache mount (not the layer), copy the finished binary out in the 23 + # same RUN so it survives into the image. 24 + RUN --mount=type=cache,target=/usr/local/cargo/registry \ 25 + --mount=type=cache,target=/app/target \ 26 + cargo build --release -p slingshot \ 27 + && cp target/release/slingshot /usr/local/bin/slingshot 28 + 29 + FROM debian:12.14-slim AS runtime 30 + 31 + # ca-certificates for TLS to jetstream/plc; libssl3 for native-tls at runtime. 32 + RUN apt-get update && apt-get install -y --no-install-recommends \ 33 + ca-certificates \ 34 + libssl3 \ 35 + && rm -rf /var/lib/apt/lists/* 36 + 37 + COPY --from=builder /usr/local/bin/slingshot /usr/local/bin/slingshot 38 + 39 + # slingshot serves ./static/index.html relative to its working directory. 40 + WORKDIR /app 41 + COPY --from=builder /app/slingshot/static ./static 42 + 43 + RUN mkdir -p /data 44 + VOLUME ["/data"] 45 + 46 + ENTRYPOINT ["slingshot"] 47 + CMD ["--help"]