Commit 9e1d6450 authored by Elisabetta Giani's avatar Elisabetta Giani
Browse files

TestPipeline: another test...

parent e12c7e62
Loading
Loading
Loading
Loading
Loading
+8 −5
Original line number Diff line number Diff line
@@ -120,6 +120,9 @@ linting:csp-lmc-common:
.publish_python_common:
  stage: publish_common
  image: nexus.engageska-portugal.pt/ska-docker/ska-python-buildenv:latest
  variables:
    TWINE_USERNAME: $TWINE_USERNAME
    TWINE_PASSWORD: $TWINE_PASSWORD
  tags:
    - k8srunner
  before_script:
@@ -128,16 +131,16 @@ linting:csp-lmc-common:
.publish_python_dev_common:
  extends: .publish_python_common
  except: [master]
  variables:
    PACKAGE: $(ls -d ./dist/*.whl | grep $CI_COMMIT_SHORT_SHA)
  script:
    - PACKAGE = $(ls -d ./dist/*.whl | grep $CI_COMMIT_SHORT_SHA)
    - cd $BUILD_PATH
    - cat $TESTPIPRC  > /tmp/.pypirc
    - twine upload --repository gitlab --config-file /tmp/.pypirc --verbose $(ls -d ./dist/*.whl | grep $CI_COMMIT_SHORT_SHA)
    - echo $PACKAGE
    - TWINE_PASSWORD=${CI_JOB_TOKEN} TWINE_USERNAME=gitlab-ci-token python3 -m twine upload --repository-url https://gitlab.com/api/v4/projects/${CI_PROJECT_ID}/packages/pypi $PACKAGE 

.publish_python_release_common:
  extends: .publish_python_common
  variables:
    TWINE_USERNAME: $TWINE_USERNAME
    TWINE_PASSWORD: $TWINE_PASSWORD
  only: [master]
  script:
    - cd $COMMON_BUILD_PATH