Skip to content

Commit

Permalink
more libs
Browse files Browse the repository at this point in the history
  • Loading branch information
mojotalantikite committed Jan 29, 2024
1 parent 2aabcee commit 53a7cd4
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions services/uploads/src/avLayer/build/build.sh
Original file line number Diff line number Diff line change
@@ -1,21 +1,25 @@
#!/usr/bin/env bash

set -e

echo "building clamav lambda layer..."
VERSION=${VERSION:-1.0.3-30349}
echo "building clamav (${VERSION}) lambda layer..."
uname -m
rm -rf bin
rm -rf lib
rm lambda_layer.zip || true

yum update -y
amazon-linux-extras install epel -y
yum install -y cpio yum-utils tar.x86_64 gzip zip
yum install -y cpio yum-utils zip

# extract binaries for clamav, json-c, pcre
mkdir -p /tmp/build
pushd /tmp/build

# Download the clamav package that includes unrar
curl -L --output clamav.rpm "https://www6.atomicorp.com/channels/atomic/centos/7/x86_64/RPMS/clamav-${VERSION}.el7.art.x86_64.rpm"
rpm2cpio clamav.rpm | cpio -vimd

# Download libcrypt.so.1
curl -L --output glibc-2.17-317.el7.x86_64.rpm http://mirror.centos.org/centos/7/os/x86_64/Packages/glibc-2.17-317.el7.x86_64.rpm
rpm2cpio glibc*.rpm | cpio -vimd
Expand Down

0 comments on commit 53a7cd4

Please sign in to comment.