Skip to content

Initial Release

Initial Release #91

Workflow file for this run

name: Docker
on: [push, pull_request]
jobs:
# clean up
clean-up:
name: Clean up
runs-on: self-hosted
steps:
- name: Clean up
run: rm -rf *
# create carla-prerequisites image
create-carla-prerequisites-image:
name: Create carla-prerequisites image
runs-on: self-hosted
needs: clean-up
steps:
- uses: docker/build-push-action@v5
name: Build image
with:
file: Util/Docker/Prerequisites.Dockerfile
tags: carla-prerequisites
no-cache: true
build-args: |
EPIC_USER=${{ secrets.EPIC_USER }}
EPIC_PASS=${{ secrets.EPIC_PASS }}
# create and push carla-source image
create-carla-source-image:
name: Create carla-source image
runs-on: self-hosted
needs: create-carla-prerequisites-image
steps:
- uses: actions/checkout@v3
name: Checkout repository
with:
submodules: true
- uses: docker/login-action@v3
name: Login to Docker Hub
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- uses: docker/build-push-action@v5
name: Build and push image
with:
file: Util/Docker/Carla.Dockerfile
tags: rwthika/carla-simulator:source
no-cache: true
push: true # TODO set to false for rwthika
context: .
# provide artifacts and releases
provide-artifacts:
name: Provide carla artifacts
runs-on: self-hosted
needs: create-carla-source-image
steps:
# provide carla-package
- uses: shrink/actions-docker-extract@v3
name: Extract carla-package
with:
image: rwthika/carla-simulator:source
path: home/carla/carla/Dist
destination: artifacts/
# provide carla-python-api
- uses: shrink/actions-docker-extract@v3
name: Extract carla-python-api
id: extract_python_api
with:
image: rwthika/carla-simulator:source
path: home/carla/carla/PythonAPI
destination: artifacts/
# create archive for release
- name: Create archive
if: startsWith(github.ref, 'refs/tags')
run: tar -czvf artifacts/PythonAPI.tar.gz artifacts/PythonAPI
# provide release
- uses: ncipollo/release-action@v1
name: Create Release
if: startsWith(github.ref, 'refs/tags')
with:
allowUpdates: true
tag: ${{ github.ref_name }}
commit: ${{ github.sha }}
artifacts: artifacts/PythonAPI.tar.gz
token: ${{ secrets.PAT }}
# create vulkan-base for carla release
create-vulkan-base-image:
name: Create vulkan-base image
runs-on: self-hosted
needs: provide-artifacts
steps:
- uses: docker/build-push-action@v5
name: Build image
with:
file: Util/Docker/vulkan-base/Vulkan.Dockerfile
tags: vulkan-base
no-cache: true
build-args: |
BASE_DIST=ubuntu22.04
CUDA_VERSION=12.2.0
context: Util/Docker/vulkan-base
# create and push carla image
create-carla-image:
name: Create carla image
runs-on: self-hosted
needs: create-vulkan-base-image
steps:
- uses: docker/login-action@v3
name: Login to Docker Hub
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Extract artifact
run: mkdir -p build && tar -xvzf artifacts/Dist/*.tar.gz -C build
- uses: docker/build-push-action@v5
name: Build and push
with:
file: build/Dockerfile
tags: rwthika/carla-simulator
no-cache: true
context: build
push: true