Skip to content

Commit

Permalink
sleepy
Browse files Browse the repository at this point in the history
  • Loading branch information
kachick committed Mar 8, 2024
1 parent 57f2fea commit c9e06ce
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions .github/workflows/container.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,18 +67,21 @@ jobs:
- name: Build Image
uses: redhat-actions/buildah-build@7a95fa7ee0f02d552a32753e7414641a04307056 #v2.13
with:
image: systemd-prepared
image: systemd
tags: latest ${{ github.sha }} ${{ needs.get-meta.outputs.started_at }}
containerfiles: |
containers/Containerfile
oci: true
- name: Run and commit Nix operations by the user while running the systemd
run: |
set -euxo pipefail
podman run --name running-systemd --rm systemd-prepared &
podman exec --user=user -it running-systemd /provisioner/needs_systemd.bash
podman commit running-systemd ran-nix-commands-by-user
podman kill running-systemd
podman run --name 'systemd' --rm systemd &
sleep 3
container_name="$(podman ps --sort=created --format {{.Names}} | tail -1)"
[ -n "$container_name" ] # May be fail with bg timing
podman exec --user=user -it "$container_name" /provisioner/needs_systemd.bash
podman commit "$container_name" ran-nix-commands-by-user
podman kill "$container_name"
- name: Finalize the image
id: build-image
uses: redhat-actions/buildah-build@7a95fa7ee0f02d552a32753e7414641a04307056 #v2.13
Expand Down

0 comments on commit c9e06ce

Please sign in to comment.