How to run AWS EC2 Private subnet on GIT

Viewed 22

How to run AWS EC2 Private subnet on GIT

Currently I am using this YAML File

name: CI

on: push: branches: [ "main" ] pull_request: branches: [ "main" ]

workflow_dispatch: inputs: choice: type: choice description: Environment options: - test - dev - uat

jobs:

build: runs-on: ubuntu-latest

steps:
  - uses: actions/checkout@v3

  - name: setup-jmeter
    run: |
      sudo apt-get update
      sudo apt install curl -y
      sudo apt install -y default-jdk
      sudo curl -O https://archive.apache.org/dist/jmeter/binaries/apache-jmeter-5.3.tgz 
      sudo tar -xvf apache-jmeter-5.3.tgz
      cd $GITHUB_WORKSPACE/apache-jmeter-5.3/lib && sudo curl -O https://repo1.maven.org/maven2/kg/apc/cmdrunner/2.2.1/cmdrunner-2.2.1.jar
      cd $GITHUB_WORKSPACE/apache-jmeter-5.3/lib/ext && sudo curl -O https://repo1.maven.org/maven2/kg/apc/jmeter-plugins-manager/1.6/jmeter-plugins-manager-1.6.jar
      cd $GITHUB_WORKSPACE/apache-jmeter-5.3/lib && sudo java -jar cmdrunner-2.2.1.jar --tool org.jmeterplugins.repository.PluginManagerCMD install-all-except jpgc-hadoop,jpgc-oauth,ulp-jmeter-autocorrelator-plugin,ulp-jmeter-videostreaming-plugin,ulp-jmeter-gwt-plugin,tilln-iso8583
      sudo wget https://github.com/AnthonyBobsin/latency-lingo-cli/releases/download/v1.1.0/latency-lingo-cli_1.1.0_Linux_x86_64.tar.gz && sudo tar -xzf latency-lingo-cli_1.1.0_Linux_x86_64.tar.gz
  
  - name: run-jmeter-test
    run: |
      echo "choice is ${{ github.event.inputs.choice }}" / ${{ inputs.choice }}
      $GITHUB_WORKSPACE/apache-jmeter-5.3/bin/./jmeter.sh -n -t testGIT.jmx -Jchoice="${{ github.event.inputs.choice }}" -l result.jtl -e -o index.html

  - name: run-latency-lingo
    run: |
      cd $GITHUB_WORKSPACE/latency-lingo-cli publish --file result.jtl \ --label "Hello Secret Lingo Report"
  
      
  - name: Upload Results
    uses: actions/upload-artifact@v2
    with:
      name: jmeter-results
      path: result.jtl


  - name: Upload HTML
    uses: actions/upload-artifact@v2
    with:
      name: jmeter-results-HTML
      path: index.html

Unfortunately I'm encountering an error upon accessing this URL: "Non HTTP response code"

Expected Result: I should able to access/connect to this URL: https://test-nlb-internal-a1468eb32e9cf142.elb.us-east-1.amazonaws.com

Note: I am able to access this on AWS EC2 Instance. Thank you so much in advance.

0 Answers
Related