Can not upload test reports to TestOps with Katalon image and uploader.jar

Hi to all,
I´m struggling on uploading test report data to TestOps.
I´m useing GitLab CI with shared runners which are provided in our companies network. For our shared runners internet access is possible through a proxy server only.

Problem: credentials are ignored

In my .gitlab-ci.yml I´m doing this:

image: docker.server/katalonstudio/katalon:8.2.5

    variables:
      KATALON_PROJECT_DIR: $CI_PROJECT_DIR
      KATALON_API_KEY: $KATALON_API_KEY  

    services:
      - docker:dind

    stages:
      - QA-Stage

    QA-Stage:
      stage: QA-Stage
      tags:
        - qa-runner

     script:
        - katalonc.sh -browserType="Chrome" -executionProfile="Emulation"   -retry=2 -retryStrategy=failedExecutions -projectPath=$KATALON_PROJECT_DIR -apiKey=$KATALON_API_KEY   -testSuitePath="Test Suites/Docker-Test/GLCI"  -proxy.auth.option=MANUAL_CONFIG -proxy.auth.server.type=HTTP -proxy.auth.server.address=proxy-at.my.org -proxy.auth.server.port=3128

        - export no_proxy="127.0.0.1,localhost"
        - export NO_PROXY="127.0.0.1,localhost"

        - export http_proxy="proxy-at.my.org:3128"
        - export HTTP_PROXY="proxy-at.my.org:3128"
        - export https_proxy="proxy-at.my.org:3128"
        - export HTTPS_PROXY="proxy-at.my.org:3128"

        - wget https://github.com/katalon-studio/report-uploader/releases/download/v0.0.8/katalon-report-uploader-0.0.8.jar -P /builds/ns/my_apps
        - mv /builds/ns/my_apps/katalon-report-uploader-0.0.8.jar /builds/ns/my_apps/katalon-report-uploader.jar 
       
        - java -jar /builds/ns/my_apps/katalon-report-uploader.jar --projectId=654321 --path="/builds/ns/my_apps/Reports"  --password=111111-222-33333-4444 --type=katalon 

When I try this I get the error message “Connection timed out” for the last command line.

I also tried to pass the proxy params like this(same error: Connection timed out):
- java -jar /builds/ns/my_apps/katalon-report-uploader.jar -projectId=654321 -path="/builds/ns/my_apps/Reports" -password=111111-222-33333-4444 -type=katalon -Dhttp.proxyHost="proxy-at.my.org" -Dhttp.proxyPort="3128" -Dhttp.nonProxyHosts="127.0.0.1|localhost"

Next I tried (added variables above to the variables section, replaced last command line with):
SERVER: https://analytics.katalon.com
EMAIL: mistermustermann@domain.com
PASSWORD: $MY_PW
PROJECT_ID: 654321
TYPE: katalon
REPORT_PATH: /builds/ns/my_apps/Reports

- wget https://raw.githubusercontent.com/katalon-studio/report-uploader/v0.0.8/uploader.sh -P /builds/ns/my_apps
 - chmod 755 /builds/ns/my_apps/uploader.sh 
 - /builds/ns/my_apps/uploader.sh

None of all of my tries worked for me!

If I start this command from my local machine, it works fine:
- java -jar /builds/ns/my_apps/katalon-report-uploader.jar --projectId=654321 --path="/builds/ns/my_apps/Reports" --password=111111-222-33333-4444 --type=katalon

Does someone have an idea what´s wrong?

You mention that it works from your machine, but I am assuming your machine does not have to go through the proxy to get to the Internet. Is that right? It seems likely that the proxy is the issue.

I’m looking at the reporter to see how I think it should be behaving given your proxy configuration. Will report back.

Yes, you´re right. My local machine has direct internet access.

So, the solution is trivial:
my machine

Solved with two shared runners and artifactory server in between.

The second runner which uploads the reports to the TestOps server has direct internet access. So I´m not forced to use proxy params.

Useing: https://github.com/katalon-studio/report-uploader/releases/tag/v0.0.10-beta

1 Like