mockbuild: add a swapfile to el8 aarch64 builds
The pulp client is very large and defines a lot of symbols in on package, which causes very large memory usage on el8 aarch64 (presumably because of 64k page sizes). Adding a 1 GiB swapfile fixes the issue in our CI runners.
This commit is contained in:
parent
f4afef2890
commit
5a337cd274
1 changed files with 8 additions and 0 deletions
|
|
@ -72,6 +72,14 @@ if [[ "$ID" == rhel ]] && sudo subscription-manager status; then
|
|||
DISTRO_VERSION=rhel-${VERSION_ID%.*}-cdn
|
||||
fi
|
||||
|
||||
# EL8 aarch64 builds run out of memory and get killed. A swapfile fixes this.
|
||||
if [[ "$PLATFORM_ID" == "platform:el8" ]] && [[ "${ARCH}" == "aarch64" ]]; then
|
||||
sudo dd if=/dev/zero of=/swapfile bs=1M count=1024
|
||||
sudo chmod 600 /swapfile
|
||||
sudo mkswap /swapfile
|
||||
sudo swapon /swapfile
|
||||
fi
|
||||
|
||||
# Relative path of the repository – used for constructing both the local and
|
||||
# remote paths below, so that they're consistent.
|
||||
REPO_PATH=osbuild-composer/${DISTRO_VERSION}/${ARCH}/${COMMIT}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue