Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: update noctilucent, turn on golang feature #26146

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion packages/aws-cdk/generate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ HERE

# Build noctilucent package in a Docker/Finch VM
NOCTILUCENT_GIT="https://github.com/iph/noctilucent.git"
NOCTILUCENT_COMMIT_ID="6da7c9fade55f8443bba7b8fdfcd4ebfe5208fb1"
NOCTILUCENT_COMMIT_ID="b7d9a0dd8e4f060a0964f30c326aef276a4e42cd"
if [ "$(cat lib/vendor/noctilucent/.version 2>/dev/null || echo '')" == "${NOCTILUCENT_GIT}:${NOCTILUCENT_COMMIT_ID}" ]
then
echo "⏭️ Noctilucent WASM binary is up-to date, skipping build..."
Expand All @@ -27,6 +27,7 @@ else
${CDK_DOCKER:-docker} build --rm \
--build-arg NOCTILUCENT_GIT="${NOCTILUCENT_GIT}" \
--build-arg NOCTILUCENT_COMMIT_ID="${NOCTILUCENT_COMMIT_ID}" \
--build-arg FEATURES=${NOCTILUCENT_FEATURES:-golang} \
--file lib/vendor/noctilucent/Dockerfile \
--target wasm \
--output type=local,dest=lib/vendor/noctilucent \
Expand Down
12 changes: 9 additions & 3 deletions packages/aws-cdk/lib/vendor/noctilucent/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,21 @@ RUN cargo install wasm-opt wasm-pack

ARG NOCTILUCENT_GIT
ARG NOCTILUCENT_COMMIT_ID
ARG FEATURES=""

# Check out noctilucent
RUN git clone "${NOCTILUCENT_GIT}" "${TMPDIR}/noctilucent" \
&& git -C "${TMPDIR}/noctilucent" checkout -b wasm "${NOCTILUCENT_COMMIT_ID}"

# Build noctilucent to WASM
RUN cd "${TMPDIR}/noctilucent" \
&& wasm-pack build --target=nodejs --out-name=index --out-dir=/wasm-out \
&& rm --force /wasm-out/.gitignore /wasm-out/README.md /wasm-out/package.json \
RUN cd "${TMPDIR}/noctilucent" \
&& wasm-pack build \
--features=${FEATURES} \
--no-pack \
--out-dir=/wasm-out \
--out-name=index \
--target=nodejs \
&& rm --force /wasm-out/.gitignore /wasm-out/README.md \
&& echo "${NOCTILUCENT_GIT}:${NOCTILUCENT_COMMIT_ID}" > /wasm-out/.version

####################################################################################################
Expand Down