Skip to content

Commit

Permalink
Use bsdtar
Browse files Browse the repository at this point in the history
It can unarchive zip files seamlessly
  • Loading branch information
aeifn committed Jul 3, 2024
1 parent cbfb918 commit ecb6d7f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ RUN apt-get update && \
update-ca-certificates

# Install git & Node.JS
RUN apt-get clean && apt-get update && apt-get install -y git-core nodejs npm && \
RUN apt-get clean && apt-get update && apt-get install -y \
git-core nodejs npm \
libarchive-tools && \
rm -rf /var/lib/apt/lists/*

COPY ./util/docker-entrypoint.sh /
Expand Down
2 changes: 1 addition & 1 deletion lib/DownloadManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ class DownloadManager {
var fulfill;
var promise = new Promise(x => fulfill = x);
logger.info(`tar -xf ${tarballPath} -C ${folderPath}`);
exec('tar', ['-xf', tarballPath, '-C', folderPath], (err, stdout, stderr) => {
exec('bsdtar', ['-xf', tarballPath, '-C', folderPath], (err, stdout, stderr) => {
if (err) {
utils.rmdirRecursive(folderPath);
logger.error(`ERROR: Downloader failed to extract tarball. ${err.message}`);
Expand Down

0 comments on commit ecb6d7f

Please sign in to comment.