CI: mount tmpfs as step instead of container --tmpfs
--tmpfs with size= in container options may not parse correctly on GH Actions. Mount tmpfs as a run step for full control.
This commit is contained in:
@@ -12,7 +12,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container:
|
container:
|
||||||
image: artixlinux/artixlinux:base
|
image: artixlinux/artixlinux:base
|
||||||
options: --privileged --tmpfs /var/lib/artools/buildiso:exec,suid,dev,size=12G
|
options: --privileged
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
@@ -53,15 +53,11 @@ jobs:
|
|||||||
lsblk
|
lsblk
|
||||||
free -h
|
free -h
|
||||||
|
|
||||||
- name: Create swap space
|
- name: Setup tmpfs for build directory
|
||||||
run: |
|
run: |
|
||||||
dd if=/dev/zero of=/swapfile bs=1M count=12288
|
mkdir -p /var/lib/artools/buildiso
|
||||||
chmod 600 /swapfile
|
mount -t tmpfs -o size=12G,exec,suid,dev tmpfs /var/lib/artools/buildiso
|
||||||
LOOPDEV=$(losetup -f)
|
mount | grep buildiso
|
||||||
losetup "$LOOPDEV" /swapfile
|
|
||||||
mkswap "$LOOPDEV"
|
|
||||||
swapon "$LOOPDEV"
|
|
||||||
swapon --show
|
|
||||||
|
|
||||||
- name: Build ISO
|
- name: Build ISO
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
Reference in New Issue
Block a user