Skip to content

Commit

Permalink
build virtiofsd from source
Browse files Browse the repository at this point in the history
  • Loading branch information
stlankes committed Feb 22, 2025
1 parent 2a23a25 commit ec599e4
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,15 @@ jobs:
- name: Create dockerfile for Ubuntu
run: |
cat << END > Dockerfile
FROM rust:1.84.1-bookworm as builder
RUN apt update
RUN apt install -y --no-install-recommends libcap-ng-dev libseccomp-dev
RUN cargo install --tag v1.13.1 --git https://gitlab.com/virtio-fs/virtiofsd.git
FROM ubuntu:latest
RUN apt update
RUN apt install -y --no-install-recommends libcap-ng0 libseccomp2 qemu-system-x86 net-tools virtiofsd
RUN apt install -y --no-install-recommends libcap-ng0 libseccomp2 qemu-system-x86 net-tools
COPY --from=builder /usr/local/cargo/bin/virtiofsd /usr/bin/virtiofsd
RUN chmod 0755 /usr/bin/virtiofsd
END
- name: Build and push container
uses: docker/build-push-action@v6
Expand All @@ -39,8 +45,13 @@ jobs:
- name: Create dockerfile for Alpine
run: |
cat << END > Dockerfile
FROM alpine:latest as builder
RUN apk add --no-cache rust cargo libseccomp-dev libcap-ng-dev
RUN cargo install --tag v1.13.1 --git https://gitlab.com/virtio-fs/virtiofsd.git
FROM alpine:latest
RUN apk add --no-cache qemu qemu-system-x86_64 libseccomp libcap-ng virtiofsd
RUN apk add --no-cache qemu qemu-system-x86_64 libseccomp libcap-ng
COPY --from=builder /root/.cargo/bin/virtiofsd /usr/bin/virtiofsd
RUN chmod 0755 /usr/bin/virtiofsd
END
- name: Build and push container
uses: docker/build-push-action@v6
Expand Down

0 comments on commit ec599e4

Please sign in to comment.