Skip to content

Commit

Permalink
push only gcc images
Browse files Browse the repository at this point in the history
  • Loading branch information
koide3 committed Jul 10, 2024
1 parent bafd4e3 commit c734fc6
Show file tree
Hide file tree
Showing 5 changed files with 26 additions and 8 deletions.
22 changes: 18 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,17 +32,31 @@ jobs:

- name: Docker login
continue-on-error: true
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_TOKEN }}

- name: Docker build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v6
with:
tag: koide3/gtsam_points:${{ matrix.DISTRO.ubuntu }}.${{ matrix.DISTRO.suffix }}
tags: koide3/gtsam_points:${{ matrix.DISTRO.ubuntu }}
file: ${{github.workspace}}/docker/ubuntu/Dockerfile.${{ matrix.DISTRO.suffix }}
build-args: |
BASE_IMAGE=koide3/gtsam_docker:${{ matrix.DISTRO.ubuntu }}
context: .
push: ${{ github.event_name != 'push' }}
push: ${{ github.event_name == 'push' && contains(matrix.DISTRO.suffix, 'gcc') }}

dispatch:
needs: build
strategy:
matrix:
repo: ['koide3/glim']
runs-on: ubuntu-latest
steps:
- name: Repository Dispatch
uses: peter-evans/repository-dispatch@v3
with:
token: ${{ secrets.PAT }}
repository: ${{ matrix.repo }}
event-type: trigger-event
3 changes: 2 additions & 1 deletion docker/ubuntu/Dockerfile.gcc
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ RUN cmake .. \
-DCMAKE_BUILD_TYPE=Release && \
make -j$(nproc) && \
make test && \
make install
make install && \
rm -rf /root/gtsam_points/build

CMD ["bash"]
3 changes: 2 additions & 1 deletion docker/ubuntu/Dockerfile.gcc.cuda
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ RUN cmake .. \
-DBUILD_WITH_CUDA_MULTIARCH=ON \
-DCMAKE_BUILD_TYPE=Release && \
make -j$(nproc) && \
make install
make install && \
rm -rf /root/gtsam_points/build

CMD ["bash"]
3 changes: 2 additions & 1 deletion docker/ubuntu/Dockerfile.llvm
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ RUN CC=clang CXX=clang++ \
-DCMAKE_BUILD_TYPE=Release && \
make -j$(nproc) && \
make test && \
make install
make install && \
rm -rf /root/gtsam_points/build

CMD ["bash"]
3 changes: 2 additions & 1 deletion docker/ubuntu/Dockerfile.llvm.cuda
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ RUN CC=clang CXX=clang++ \
-DBUILD_WITH_CUDA_MULTIARCH=ON \
-DCMAKE_BUILD_TYPE=Release && \
make -j$(nproc) && \
make install
make install && \
rm -rf /root/gtsam_points/build

CMD ["bash"]

0 comments on commit c734fc6

Please sign in to comment.