* +podman

* +podman

* weird fixes to make hacks easier to read (maybe)

---------

Co-authored-by: Jacob Heider <jacob@tea.xyz>
This commit is contained in:
ABevier 2023-05-12 19:19:16 -04:00 committed by GitHub
parent d1eaadf428
commit 07efea2831
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -0,0 +1,54 @@
distributable:
url: https://github.com/containers/podman/archive/refs/tags/v{{version}}.tar.gz
strip-components: 1
versions:
github: containers/podman/releases/tags
platforms:
- darwin
#fixme: - linux once qemu is built
provides:
- bin/podman
- bin/podman-mac-helper
dependencies:
qemu.org: '*'
github.com/containers/gvisor-tap-vsock: '*'
build:
dependencies:
go.dev: ^1.18
tea.xyz/gx/cc: c99
tea.xyz/gx/make: '*'
script:
# podman searches a compile-time configured set of paths for helper binaries
# so we add a relative lookup for the major version of gvproxy we require
- run: |
sed -i.bak -f $PROP config_{darwin,linux}.go
rm config_{darwin,linux}.go.bak
working-directory: vendor/github.com/containers/common/pkg/config
prop: |-
s_\(^var defaultHelperBinariesDir.*\)_\
\1\n "\$BINDIR/../../../$GVISOR_MAJOR/bin",_
- make --jobs {{ hw.concurrency }} podman-remote
- make --jobs {{ hw.concurrency }} podman-mac-helper
- mkdir -p "{{ prefix }}"/bin
- mv bin/"{{ hw.platform }}"/* "{{ prefix }}"/bin
- ln -s podman "{{ prefix }}"/bin/podman-remote
env:
# path for gvproxy to add to platform config
GVISOR_MAJOR: |-
$(cd "{{deps.github.com/containers/gvisor-tap-vsock.prefix}}/../\
/v{{deps.github.com/containers/gvisor-tap-vsock.version.major}}" \
&& pwd | sed -e "s_$TEA_PREFIX/__")
CGO_ENABLED: 1
test:
script: |
podman-remote -v | grep "podman-remote version {{ version }}"
(podman info 2>&1 || true) | grep "Cannot connect to Podman."
(podman machine init --image-path fake-testimage fake-testvm 2>&1 || true) | grep "Error: open fake-testimage: no such file or directory"