Skip to content

Commit

Permalink
Merge pull request #99 from nansencenter/issue98_idf_converter_pypi
Browse files Browse the repository at this point in the history
Use idf_converter from pypi
  • Loading branch information
aperrin66 authored Feb 15, 2024
2 parents 21a3c3d + 78de5c5 commit 7d79dce
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 12 deletions.
12 changes: 2 additions & 10 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
BASE_IMAGE: "${{ vars.DOCKER_ORG }}/geospaas:2.5.2-python${{ matrix.python_version }}"
IMAGE_NAME_WORKER: "${{ vars.DOCKER_ORG }}/geospaas_processing_worker"
IMAGE_NAME_CLI: "${{ vars.DOCKER_ORG }}/geospaas_processing_cli"
IDF_CONVERTER_VERSION: '0.1.324'
IDF_CONVERTER_VERSION: '0.1.394'
GEOSPAAS_DB_HOST: 'db'
GEOSPAAS_DB_USER: 'test'
GEOSPAAS_DB_PASSWORD: ${{ secrets.GEOSPAAS_DB_PASSWORD }}
Expand Down Expand Up @@ -100,15 +100,6 @@ jobs:
run: pip install coveralls && coveralls --service=github

############# Build worker image #############
- name: Get IDF converter
env:
API_TOKEN_GITHUB: ${{ secrets.API_TOKEN_GITHUB }}
run: >
curl -L -o ./idf_converter.tar.gz
-H "Authorization: token ${API_TOKEN_GITHUB}"
-H 'Accept: application/vnd.github.v3.raw'
"https://api.github.com/repos/nansencenter/idf-converter/contents/idf_converter-${IDF_CONVERTER_VERSION}.tar.gz"
- name: Build worker docker image
uses: docker/build-push-action@v5
with:
Expand All @@ -117,6 +108,7 @@ jobs:
build-args: |
BASE_IMAGE=${{ env.BASE_IMAGE }}
GEOSPAAS_PROCESSING_RELEASE=${{ github.ref_type == 'tag' && github.ref_name || '0.0.0' }}
IDF_CONVERTER_VERSION=${{ env.IDF_CONVERTER_VERSION }}
push: ${{ github.event_name == 'release' }}
tags: |
${{ env.IMAGE_NAME_WORKER }}:${{ github.ref_name }}-python${{ matrix.python_version }}
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile_worker
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ RUN pip install --upgrade --no-cache-dir \

FROM base as full

COPY idf_converter.tar.gz /tmp/idf_converter.tar.gz
RUN pip install /tmp/idf_converter.tar.gz
ARG IDF_CONVERTER_VERSION='0.1.*'
RUN pip install "idf_converter==${IDF_CONVERTER_VERSION}"

WORKDIR /tmp/setup
COPY setup.py README.md ./
Expand Down
1 change: 1 addition & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
'graylog': ['graypy'],
'parallel_download': ['redis'],
'worker': ['celery==4.4.*', 'django-celery-results==1.2.*'],
'idf': ['idf_converter'],
},
package_data={
'': [
Expand Down

0 comments on commit 7d79dce

Please sign in to comment.