You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

52 lines
1.3 KiB

8 years ago
  1. #!/bin/bash
  2. set -e
  3. source $(dirname $0)/helpers.sh
  4. it_can_deploy_release_to_artifactory() {
  5. # local local_ip=$(find_docker_host_ip)
  6. #local_ip=localhost
  7. artifactory_ip=$ART_IP
  8. TMPDIR=/tmp
  9. local src=$(mktemp -d $TMPDIR/in-src.XXXXXX)
  10. local endpoint="http://${artifactory_ip}:8081/artifactory"
  11. local regex="ecd-front-(?<version>.*).tar.gz"
  12. local folder="/generic/ecd-front"
  13. local version="20161109222826"
  14. local username="${ART_USER}"
  15. local password="${ART_PWD}"
  16. local repository="/generic/ecd-front"
  17. local file="ecd-front-(?<version>.*).tar.gz"
  18. local version=20161109222826
  19. deploy_without_credentials $endpoint $regex $repository $file $version $src
  20. }
  21. it_can_deploy_release_to_artifactory_with_credentials() {
  22. artifactory_ip=$ART_IP
  23. TMPDIR=/tmp
  24. local src=$(mktemp -d $TMPDIR/in-src.XXXXXX)
  25. local endpoint="http://${artifactory_ip}:8081/artifactory"
  26. local regex="ecd-front-(?<version>.*).tar.gz"
  27. local username="${ART_USER}"
  28. local password="${ART_PWD}"
  29. local repository="/generic/ecd-front"
  30. local file="ecd-front-(?<version>.*).tar.gz"
  31. local version=20161109222826
  32. deploy_with_credentials $endpoint $regex $repository $file $version $src $username $password
  33. }
  34. run it_can_deploy_release_to_artifactory_with_credentials
  35. run it_can_deploy_release_to_artifactory