Skip to content

Commit

Permalink
show full docker output and remove requirements txt
Browse files Browse the repository at this point in the history
  • Loading branch information
jyjblrd committed Apr 8, 2024
1 parent e209914 commit 1dbddbd
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 36 deletions.
68 changes: 36 additions & 32 deletions .github/workflows/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,42 +35,44 @@ jobs:
# target-ros2-distro: iron
# skip-tests: true

build-docker:
runs-on: ubuntu-latest
env:
DOCKER_IMAGE: joshuabird/part_ii_project
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
DOCKER_TARGET_PLATFORM: linux/arm64
steps:
- name: Checkout the code
uses: actions/checkout@v1
# build-docker:
# runs-on: ubuntu-latest
# env:
# DOCKER_IMAGE: joshuabird/part_ii_project
# DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
# DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
# DOCKER_TARGET_PLATFORM: linux/arm64
# PROGRESS_NO_TRUNC: 1
# steps:
# - name: Checkout the code
# uses: actions/checkout@v1

- name: Set up Docker Buildx
uses: crazy-max/ghaction-docker-buildx@v1
with:
version: latest
# - name: Set up Docker Buildx
# uses: crazy-max/ghaction-docker-buildx@v1
# with:
# version: latest

- name: Prepare
if: success()
id: prepare
run: |
echo ::set-output name=docker_platform::${DOCKER_TARGET_PLATFORM}
echo ::set-output name=docker_image::${DOCKER_IMAGE}
# - name: Prepare
# if: success()
# id: prepare
# run: |
# echo ::set-output name=docker_platform::${DOCKER_TARGET_PLATFORM}
# echo ::set-output name=docker_image::${DOCKER_IMAGE}

- name: Docker Login
if: success()
run: |
echo "${DOCKER_PASSWORD}" | docker login --username "${DOCKER_USERNAME}" --password-stdin
# - name: Docker Login
# if: success()
# run: |
# echo "${DOCKER_PASSWORD}" | docker login --username "${DOCKER_USERNAME}" --password-stdin

- name: Run Buildx (push image)
if: success()
run: |
docker buildx build \
--platform ${{ steps.prepare.outputs.docker_platform }} \
--tag ${{ steps.prepare.outputs.docker_image }}:latest \
--file ./Dockerfile \
--output type=image,push=true .
# - name: Run Buildx (push image)
# if: success()
# run: |
# docker buildx build \
# --platform ${{ steps.prepare.outputs.docker_platform }} \
# --tag ${{ steps.prepare.outputs.docker_image }}:latest \
# --file ./Dockerfile \
# --progress plain \
# --output type=image,push=true .

build-nvidia-jetson-docker:
runs-on: ubuntu-latest
Expand All @@ -79,6 +81,7 @@ jobs:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
DOCKER_TARGET_PLATFORM: linux/arm64
PROGRESS_NO_TRUNC: 1
steps:
- name: Checkout the code
uses: actions/checkout@v1
Expand Down Expand Up @@ -107,4 +110,5 @@ jobs:
--platform ${{ steps.prepare.outputs.docker_platform }} \
--tag ${{ steps.prepare.outputs.docker_image }}:latest \
--file ./nvidia_jetson.Dockerfile \
--progress plain \
--output type=image,push=true .
4 changes: 0 additions & 4 deletions nvidia_jetson.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,6 @@ FROM dustynv/ros:humble-ros-base-l4t-r35.3.1
# Add system packages to be installed here
RUN apt-get update && apt-get install -y git vim

# Optional python packages (better to copy requirements
COPY requirements.txt /tmp
RUN pip3 install -r /tmp/requirements.txt

#RUN mkdir -p /opt/robomaster/src
#COPY src /opt/root_ws/src

Expand Down

0 comments on commit 1dbddbd

Please sign in to comment.