Skip to content

Commit 0bcf9c3

Browse files
committed
Attempt to use colima to run docker on mac
1 parent 0097072 commit 0bcf9c3

File tree

4 files changed

+99
-57
lines changed

4 files changed

+99
-57
lines changed

.github/workflows/build.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
name: CI
22

33
on:
4-
push:
5-
branches: [ "master" ]
6-
pull_request:
7-
branches: [ "master" ]
4+
# push:
5+
# branches: [ "master" ]
6+
# pull_request:
7+
# branches: [ "master" ]
88
workflow_dispatch:
99

1010

.github/workflows/container.yml

Lines changed: 90 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -16,57 +16,98 @@ env:
1616

1717
jobs:
1818

19-
container:
20-
runs-on: ubuntu-latest
21-
timeout-minutes: 300
19+
# container:
20+
# runs-on: ubuntu-latest
21+
# timeout-minutes: 300
22+
23+
# steps:
24+
# - name: Check out
25+
# if: always()
26+
# uses: actions/checkout@v4
27+
# with:
28+
# fetch-depth: 0
29+
30+
# # - uses: hadolint/[email protected]
31+
# # with:
32+
# # dockerfile: Dockerfile
33+
# # ignore: 'DL3008,DL3013'
34+
# # verbose: true
35+
36+
# - name: Build Image
37+
# id: build_image
38+
# uses: redhat-actions/buildah-build@v2
39+
# with:
40+
# image: ${{ env.IMAGE_NAME }}
41+
# tags: ${{ env.IMAGE_TAGS }}
42+
# containerfiles: |
43+
# ./Dockerfile
44+
# build-args: |
45+
# PYNUCLEUS_BUILD_PARALLELISM=4
46+
47+
# - name: Run tests
48+
# run: |
49+
# podman run \
50+
# -e MPIEXEC_FLAGS="--allow-run-as-root --oversubscribe" \
51+
# --workdir /pynucleus \
52+
# --rm \
53+
# --entrypoint='["python3", "-m", "pytest", "--junit-xml", "test-results.xml"]' \
54+
# ${{ steps.build_image.outputs.image }}:${{ github.sha }}
55+
56+
# - name: Push To GHCR
57+
# if: github.event_name == 'push'
58+
# uses: redhat-actions/push-to-registry@v2
59+
# id: push
60+
# with:
61+
# image: ${{ steps.build_image.outputs.image }}
62+
# tags: ${{ steps.build_image.outputs.tags }}
63+
# registry: ${{ env.IMAGE_REGISTRY }}
64+
# username: ${{ env.REGISTRY_USER }}
65+
# password: ${{ env.REGISTRY_PASSWORD }}
66+
# extra-args: |
67+
# --disable-content-trust
68+
69+
# - name: Echo outputs
70+
# if: github.event_name == 'push'
71+
# run: |
72+
# echo "${{ toJSON(steps.push.outputs) }}"
73+
74+
# container-test:
75+
# needs: container
76+
# if: github.event_name == 'push'
77+
78+
# strategy:
79+
# matrix:
80+
# include:
81+
# - runner: 'ubuntu-latest'
82+
83+
# name: Container test ${{ matrix.runner }}
84+
# runs-on: ${{ matrix.runner }}
85+
86+
# steps:
87+
# - name: Check out
88+
# uses: actions/checkout@v4
89+
90+
# - name: Install podman-compose
91+
# run: pip install podman-compose
92+
93+
# - name: Run container test
94+
# run: podman-compose run quick-test
95+
96+
container-test-mac:
97+
# needs: container
98+
# if: github.event_name == 'push'
99+
100+
name: Container test MacOS
101+
runs-on: macos-latest
22102

23103
steps:
24104
- name: Check out
25-
if: always()
26105
uses: actions/checkout@v4
27-
with:
28-
fetch-depth: 0
29-
30-
# - uses: hadolint/[email protected]
31-
# with:
32-
# dockerfile: Dockerfile
33-
# ignore: 'DL3008,DL3013'
34-
# verbose: true
35-
36-
- name: Build Image
37-
id: build_image
38-
uses: redhat-actions/buildah-build@v2
39-
with:
40-
image: ${{ env.IMAGE_NAME }}
41-
tags: ${{ env.IMAGE_TAGS }}
42-
containerfiles: |
43-
./Dockerfile
44-
build-args: |
45-
PYNUCLEUS_BUILD_PARALLELISM=4
46-
47-
- name: Run tests
48-
run: |
49-
podman run \
50-
-e MPIEXEC_FLAGS="--allow-run-as-root --oversubscribe" \
51-
--workdir /pynucleus \
52-
--rm \
53-
--entrypoint='["python3", "-m", "pytest", "--junit-xml", "test-results.xml"]' \
54-
${{ steps.build_image.outputs.image }}:${{ github.sha }}
55-
56-
- name: Push To GHCR
57-
if: github.event_name == 'push'
58-
uses: redhat-actions/push-to-registry@v2
59-
id: push
60-
with:
61-
image: ${{ steps.build_image.outputs.image }}
62-
tags: ${{ steps.build_image.outputs.tags }}
63-
registry: ${{ env.IMAGE_REGISTRY }}
64-
username: ${{ env.REGISTRY_USER }}
65-
password: ${{ env.REGISTRY_PASSWORD }}
66-
extra-args: |
67-
--disable-content-trust
68-
69-
- name: Echo outputs
70-
if: github.event_name == 'push'
106+
107+
- name: Install colima
71108
run: |
72-
echo "${{ toJSON(steps.push.outputs) }}"
109+
brew install docker \
110+
colima start
111+
112+
- name: Run container test
113+
run: docker run --entrypoint="mpiexec -n 4 /pynucleus/drivers/runFractional.py" ghcr.io/sandialabs/pynucleus:latest

.github/workflows/documentation-ci.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
name: Documentation CI
22

33
on:
4-
pull_request:
5-
branches: [ "master" ]
4+
# pull_request:
5+
# branches: [ "master" ]
6+
workflow_dispatch:
67

78
permissions:
89
contents: read

.github/workflows/documentation.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
name: Documentation
22

33
on:
4-
push:
5-
branches: [ "master" ]
4+
# push:
5+
# branches: [ "master" ]
66
workflow_dispatch:
77

88
permissions:

0 commit comments

Comments
 (0)