Skip to content

Commit

Permalink
[WIP] test3
Browse files Browse the repository at this point in the history
  • Loading branch information
elandini84 committed Jan 29, 2024
1 parent d4d6b1a commit 9b70e43
Showing 1 changed file with 66 additions and 66 deletions.
132 changes: 66 additions & 66 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,69 +125,69 @@ jobs:
# fi


build-tour-docker-sim:
runs-on: ubuntu-latest
strategy:
matrix:
config:
# - {
# ros2_distro: "humble",
# base_image: "ubuntu:22.04",
# base_image_label: "ubuntu22.04",
# }
- {
ros2_distro: "iron",
base_image: "ubuntu:22.04",
base_image_label: "ubuntu22.04",
}
# - {
# ros2_distro: "humble",
# base_image: "nvidia/cuda:11.7.1-cudnn8-devel-ubuntu22.04",
# base_image_label: "cuda.11.7.1-cudnn8",
# }
- {
ros2_distro: "iron",
base_image: "nvidia/cuda:11.7.1-cudnn8-devel-ubuntu22.04",
base_image_label: "cuda.11.7.1-cudnn8",
}
steps:
- name: Info
run: |
echo "Event type: ${{github.event_name}}"
- name: Change docker to experimental mode
run: |
sudo rm -rf /etc/docker/daemon.json
echo '{"experimental": true}' | sudo tee -a /etc/docker/daemon.json
- name: Restart docker daemon
run: sudo systemctl restart docker
- uses: actions/checkout@v4
- name: Login to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build the tour core Docker image for simulation
working-directory: docker_stuff/docker_sim2/
run: |
if [ ${{ github.event_name }} == 'schedule' ]; then
echo "Building development tour core image"
sudo docker build --build-arg base_img=${{matrix.config.base_image}} --build-arg ros_distro=${{matrix.config.ros2_distro}} -t elandini84/r1images:tourSim2_${{matrix.config.base_image_label}}_${{matrix.config.ros2_distro}}_devel .
elif [ ${{ github.event_name }} == 'workflow_dispatch' ]; then
echo "Building stable tour core image"
sudo docker build --build-arg base_img=${{matrix.config.base_image}} --build-arg ros_distro=${{matrix.config.ros2_distro}} -t elandini84/r1images:tourSim2_${{matrix.config.base_image_label}}_${{matrix.config.ros2_distro}}_stable .
else
echo "Failure!"
exit 1
fi
- name: Push tourSim2 image
run: |
if [ ${{ github.event_name }} == 'schedule' ]; then
echo "Pushing tourCore2 development image"
docker push elandini84/r1images:tourSim2_${{matrix.config.base_image_label}}_${{matrix.config.ros2_distro}}_devel
elif [ ${{ github.event_name }} == 'workflow_dispatch' ]; then
echo "Pushing tourCore2 stable image"
docker push elandini84/r1images:tourSim2_${{matrix.config.base_image_label}}_${{matrix.config.ros2_distro}}_stable
else
echo "Failure!"
exit 1
fi
# build-tour-docker-sim:
# runs-on: ubuntu-latest
# strategy:
# matrix:
# config:
# # - {
# # ros2_distro: "humble",
# # base_image: "ubuntu:22.04",
# # base_image_label: "ubuntu22.04",
# # }
# - {
# ros2_distro: "iron",
# base_image: "ubuntu:22.04",
# base_image_label: "ubuntu22.04",
# }
# # - {
# # ros2_distro: "humble",
# # base_image: "nvidia/cuda:11.7.1-cudnn8-devel-ubuntu22.04",
# # base_image_label: "cuda.11.7.1-cudnn8",
# # }
# - {
# ros2_distro: "iron",
# base_image: "nvidia/cuda:11.7.1-cudnn8-devel-ubuntu22.04",
# base_image_label: "cuda.11.7.1-cudnn8",
# }
# steps:
# - name: Info
# run: |
# echo "Event type: ${{github.event_name}}"
# - name: Change docker to experimental mode
# run: |
# sudo rm -rf /etc/docker/daemon.json
# echo '{"experimental": true}' | sudo tee -a /etc/docker/daemon.json
# - name: Restart docker daemon
# run: sudo systemctl restart docker
# - uses: actions/checkout@v4
# - name: Login to DockerHub
# uses: docker/login-action@v3
# with:
# username: ${{ secrets.DOCKERHUB_USERNAME }}
# password: ${{ secrets.DOCKERHUB_TOKEN }}
# - name: Build the tour core Docker image for simulation
# working-directory: docker_stuff/docker_sim2/
# run: |
# if [ ${{ github.event_name }} == 'schedule' ]; then
# echo "Building development tour core image"
# sudo docker build --build-arg base_img=${{matrix.config.base_image}} --build-arg ros_distro=${{matrix.config.ros2_distro}} -t elandini84/r1images:tourSim2_${{matrix.config.base_image_label}}_${{matrix.config.ros2_distro}}_devel .
# elif [ ${{ github.event_name }} == 'workflow_dispatch' ]; then
# echo "Building stable tour core image"
# sudo docker build --build-arg base_img=${{matrix.config.base_image}} --build-arg ros_distro=${{matrix.config.ros2_distro}} -t elandini84/r1images:tourSim2_${{matrix.config.base_image_label}}_${{matrix.config.ros2_distro}}_stable .
# else
# echo "Failure!"
# exit 1
# fi
# - name: Push tourSim2 image
# run: |
# if [ ${{ github.event_name }} == 'schedule' ]; then
# echo "Pushing tourCore2 development image"
# docker push elandini84/r1images:tourSim2_${{matrix.config.base_image_label}}_${{matrix.config.ros2_distro}}_devel
# elif [ ${{ github.event_name }} == 'workflow_dispatch' ]; then
# echo "Pushing tourCore2 stable image"
# docker push elandini84/r1images:tourSim2_${{matrix.config.base_image_label}}_${{matrix.config.ros2_distro}}_stable
# else
# echo "Failure!"
# exit 1
# fi

0 comments on commit 9b70e43

Please sign in to comment.