feat: import IMVU products into a catalog
The importer from t5de-hub's docs/imports.md: says hello to the hub with its key pair, follows the console's config (paused, rate, jobs at a time, IMVU accounts, whose sealed passwords it keeps), claims jobs, finds each product's newest revision on IMVU's CDN, converts it (originals for placeholders, no _contents.json, ProductRating from IMVU's rating), checks it by t5de-api's pack rules and uploads it to the catalog with an import token. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
1 parent
2b0d27831e
commit
e8578e4a71
26 files changed
+2345
-1
No files matched your search
+24
@@ -0,0 +1,24 @@
|
||||
# t5de-importer in a container: a static build on distroless. Its data (key pair, accounts) goes in the /data volume.
|
||||
#
|
||||
# docker build -t t5de-importer .
|
||||
# docker run -v importer-data:/data -e HUB_URL=... -e CATALOG_ID=... -e IMPORTER_KEY=... t5de-importer
|
||||
FROM golang:1.27-alpine AS build
|
||||
RUN apk add --no-cache git
|
||||
# T5DE's modules (t5de-api) come straight from its Gitea.
|
||||
ENV GOPRIVATE=git.t5de.dev CGO_ENABLED=0
|
||||
ARG VERSION=dev
|
||||
WORKDIR /src
|
||||
COPY go.mod go.sum ./
|
||||
RUN go mod download
|
||||
COPY . .
|
||||
RUN go build -trimpath -buildvcs=false \
|
||||
-ldflags "-s -w -buildid= -X git.t5de.dev/t5de/t5de-importer/internal/buildinfo.Version=${VERSION}" \
|
||||
-o /out/t5de-importer ./cmd/t5de-importer \
|
||||
&& mkdir /out/data
|
||||
|
||||
FROM gcr.io/distroless/static-debian12:nonroot
|
||||
COPY --from=build /out/t5de-importer /t5de-importer
|
||||
COPY --from=build --chown=nonroot:nonroot /out/data /data
|
||||
ENV IMPORTER_DATA=/data
|
||||
VOLUME /data
|
||||
ENTRYPOINT ["/t5de-importer"]
|
||||
Reference in new issue
Block a user