Skip to content

Issue with config field #31

@fede843

Description

@fede843

Hi we are using this action. It was working for us until version 1.1.0 inclusive. From there, we are getting an error.

This is our workflow:

      - name: Creating config file for wait-on
        run: echo '{"headers":{"X-Header-Key":"${{ secrets.STAGING_HEALTHCHECK_KEY }}","X-Header-HealthCheck":"true"}}' > /tmp/header.json

      - name: Wating for target server
        uses: ifaxity/wait-on-action@v1.1.0
        with:
          resource: https://${{ env.stagingHost }}/lab/${{ needs.spin-up-container.outputs.domain }}/satapp/${{ env.endpointTest }}
          interval: 60000  # 1 minute
          timeout: ${{ env.MS }}
          verbose: true
          config: "/tmp/header.json"

With version 1.2.1 we get:

Run ifaxity/wait-on-action@v1.2.1
/_work/reionisation/_actions/ifaxity/wait-on-action/v1.2.1/dist/index.js:68476
        var e = new Error("Cannot find module '" + req + "'");
                ^

Error: Cannot find module '/tmp/header.json'
    at webpackEmptyContext (/_work/reionisation/_actions/ifaxity/wait-on-action/v1.2.1/dist/index.js:68476:17)
    at /_work/reionisation/_actions/ifaxity/wait-on-action/v1.2.1/dist/index.js:76187:46
    at Generator.next (<anonymous>)
    at /_work/reionisation/_actions/ifaxity/wait-on-action/v1.2.1/dist/index.js:76147:73
    at new Promise (<anonymous>)
    at __awaiter (/_work/reionisation/_actions/ifaxity/wait-on-action/v1.2.1/dist/index.js:76127:16)
    at main (/_work/reionisation/_actions/ifaxity/wait-on-action/v1.2.1/dist/index.js:76167:14)
    at /_work/reionisation/_actions/ifaxity/wait-on-action/v1.2.1/dist/index.js:76[21](https://github.com/skedgo/skedgo-java/actions/runs/9303542256/job/25606361043#step:4:22)4:5
    at /_work/reionisation/_actions/ifaxity/wait-on-action/v1.2.1/dist/index.js:76215:5
    at Object.<anonymous> (/_work/reionisation/_actions/ifaxity/wait-on-action/v1.2.1/dist/index.js:76219:3) {
  code: 'MODULE_NOT_FOUND'
}

Thanks in advance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions