Skip to content

Commit

Permalink
fix: add podman compose
Browse files Browse the repository at this point in the history
  • Loading branch information
dolcalmi committed Dec 19, 2024
1 parent f051c73 commit 9499053
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions .github/workflows/e2e-ios-podman.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,14 @@ jobs:

- name: Set up Podman and pull images in background
run: |
brew install podman
brew install podman podman-compose
podman machine init
podman machine start
podman version
# Set DOCKER_HOST environment variable
PODMAN_UID=$(id -u)
echo "PODMAN_UID=${PODMAN_UID}" >> $GITHUB_ENV
echo "DOCKER_HOST=unix:///run/user/${PODMAN_UID}/podman/podman.sock" >> $GITHUB_ENV
SOCKET_PATH=$(podman machine inspect --format '{{.ConnectionInfo.PodmanSocket.Path}}')
echo "DOCKER_HOST=unix://${SOCKET_PATH}" >> $GITHUB_ENV
# Wait for Podman to be ready
while ! podman info > /dev/null 2>&1; do
Expand All @@ -41,11 +40,11 @@ jobs:
podman info
# Start pulling images
podman compose -f dev/vendor/galoy-quickstart/docker-compose.yml pull --include-deps --quiet &
podman-compose -f dev/vendor/galoy-quickstart/docker-compose.yml pull &
- name: Initialize ci deps
env:
DOCKER_HOST: "unix:///run/user/${{ env.PODMAN_UID }}/podman/podman.sock"
DOCKER_HOST: ${{ env.DOCKER_HOST }}
run: nix develop -c tilt -f ./dev/Tiltfile ci --timeout 0

- name: Restore Node Modules Cache
Expand Down Expand Up @@ -131,7 +130,7 @@ jobs:
- name: Run E2E Tests
id: run-tests
env:
DOCKER_HOST: "unix:///run/user/${{ env.PODMAN_UID }}/podman/podman.sock"
DOCKER_HOST: ${{ env.DOCKER_HOST }}
run: |
# Wait for device to be ready
while ! xcrun simctl list devices | grep "(Booted)"; do
Expand All @@ -150,6 +149,8 @@ jobs:
- name: Cleanup Processes
if: always()
env:
DOCKER_HOST: ${{ env.DOCKER_HOST }}
run: |
# Function to kill process by PID file
kill_process() {
Expand All @@ -170,7 +171,7 @@ jobs:
done
# Additional cleanup commands
DOCKER_HOST="unix:///run/user/${{ env.PODMAN_UID }}/podman/podman.sock" nix develop -c tilt down -f ./dev/Tiltfile
nix develop -c tilt down -f ./dev/Tiltfile
pkill -f "node.*metro" || true
pkill -f "tilt" || true
podman machine stop || true
Expand Down

0 comments on commit 9499053

Please sign in to comment.