feat(pkg): Add hda-cms-extension-e2e

This commit is contained in:
T. R. Bernstein
2025-02-26 23:57:37 +01:00
parent 07ff1edd24
commit e6a5afc3cd
23 changed files with 697 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
ARG NODE_VERSION=22
####################################################################################################
## Build Packages
FROM node:${NODE_VERSION}-alpine AS builder
ARG TARGETPLATFORM
RUN <<EOF
if [ "$TARGETPLATFORM" = 'linux/arm64' ]; then
apk --no-cache add python3 py3-pip build-base
ln -sf /usr/bin/python3 /usr/bin/python
fi
EOF
WORKDIR /extensions
RUN --mount=type=bind,source=directus-extensions.json,target=/extensions/package.json npm install
RUN mkdir -p ./directus
RUN grep -lR "directus:extension" ./node_modules/* | grep -E 'package.json$' | sed 's/\/package.json//;' | xargs -r -I % mv % ./directus
FROM tabshift4docker/directus:latest
# Copy third party extensions
COPY --from=builder /extensions/directus ./extensions