Skip to content

fix urls in CI and readthedocs (#2364) #34

fix urls in CI and readthedocs (#2364)

fix urls in CI and readthedocs (#2364) #34

Workflow file for this run

name: publish-docker
on:
push:
paths-ignore:
- ".github/**"
- "docs/**"
- "resources/**"
- "service/**"
- "tests/**"
- "tools/elena/**"
- "tools/package_tools/**"
- "tools/scripts/**"
- "tools/generate_md_table.py"
- "**/*.md"
branches:
- main
tags:
- "v*.*.*"
jobs:
publish_docker_image:
runs-on: [self-hosted, linux-3090]
environment: 'prod'
env:
TAG_PREFIX: openmmlab/mmdeploy:ubuntu20.04-cuda11.3-mmdeploy
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Get mmdeploy version
if: startsWith(github.ref, 'refs/tags/') == false
run: |
echo "MMDEPLOY_VERSION=main" >> $GITHUB_ENV
echo "TAG=$TAG_PREFIX" >> $GITHUB_ENV
- name: Get mmdeploy tag
if: startsWith(github.ref, 'refs/tags/') == true
run: |
export MMDEPLOY_VERSION=$(python3 -c "import sys; sys.path.append('mmdeploy');from version import __version__;print(__version__)")
echo $MMDEPLOY_VERSION
echo "TAG=${TAG_PREFIX}${MMDEPLOY_VERSION}" >> $GITHUB_ENV
echo "MMDEPLOY_VERSION=v$MMDEPLOY_VERSION" >> $GITHUB_ENV
- name: Build Docker image
continue-on-error: true
run: |
echo $MMDEPLOY_VERSION
echo $TAG
docker build docker/Release/ -t ${TAG} --no-cache --build-arg MMDEPLOY_VERSION=${MMDEPLOY_VERSION}
- name: Push Docker image
continue-on-error: true
run: |
echo $MMDEPLOY_VERSION
echo $TAG
docker push $TAG