Skip to content

Commit

Permalink
Cache libbrotli to use it in a user's container
Browse files Browse the repository at this point in the history
Signed-off-by: Roman Nikitenko <[email protected]>
  • Loading branch information
RomanNikitenko committed Jan 18, 2024
1 parent ff0e87d commit 526e234
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
4 changes: 3 additions & 1 deletion build/dockerfiles/linux-libc-ubi9.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,9 @@ RUN NODE_ARCH=$(echo "console.log(process.arch)" | node) \
&& echo "caching /checode-compilation/.build/node/v${NODE_VERSION}/linux-${NODE_ARCH}/node" \
&& cp /usr/bin/node /checode-compilation/.build/node/v${NODE_VERSION}/linux-${NODE_ARCH}/node \
&& NODE_OPTIONS="--max_old_space_size=8500" ./node_modules/.bin/gulp vscode-reh-web-linux-${NODE_ARCH}-min \
&& cp -r ../vscode-reh-web-linux-${NODE_ARCH} /checode
&& cp -r ../vscode-reh-web-linux-${NODE_ARCH} /checode \
# cache libbrotli from this image to provide it to a user's container
&& mkdir -p /checode/ld_libs && find /usr/lib64 -name 'libbrotli*' 2>/dev/null | xargs -I {} cp -t /checode/ld_libs {}

RUN chmod a+x /checode/out/server-main.js \
&& chgrp -R 0 /checode && chmod -R g+rwX /checode
Expand Down
3 changes: 3 additions & 0 deletions build/scripts/entrypoint-volume.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ else
echo "Using linux-libc ubi8-based assembly..."
cd /checode/checode-linux-libc/ubi8 || exit
elif [ "$openssl_major_version" = "3" ]; then
export LD_LIBRARY_PATH="/checode/checode-linux-libc/ubi9/ld_libs:$LD_LIBRARY_PATH"
echo "LD_LIBRARY_PATH is: $LD_LIBRARY_PATH"

echo "Using linux-libc ubi9-based assembly..."
cd /checode/checode-linux-libc/ubi9 || exit
else
Expand Down

0 comments on commit 526e234

Please sign in to comment.