Nomad-pack in gitlab ci using nomad-pack docker image

We are planning to migrate the deployment method from levant to nomad-pack.
I tested nomad-pack locally with nomad-pack binary and also with docker image and it works.

The idea is that it clones the repo or adds registry, then runs the vendor deps command to vendor the helpers and finally nomad-pack run. All this works directly on my machine but now when I try to integrate in gitlab ci file it does not work - exits with code 127 because it cannot find the nomad-pack command.

These are the 2 steps in gitlab ci
this clones and keeps artifacts:

[quote=“sumeet.roy, post:1, topic:70476, full:true”]
We are planning to migrate the deployment method from levant to nomad-pack.
I tested nomad-pack locally with nomad-pack binary and also with docker image and it works.

The idea is that it clones the repo or adds registry, then runs the vendor deps command to vendor the helpers and finally nomad-pack run. All this works directly on my machine but now when I try to integrate in gitlab ci file it does not work - exits with code 127 because it cannot find the nomad-pack command.

These are the 2 steps in gitlab ci
this clones and keeps artifacts:

> prepare:
>   extends: .prepare
>   script:
>     - git clone https://username:${NOMADPACK_JOB_TOKEN}@gitlab.com/nomad-packs.git
>   artifacts:
>     paths:
>       - nomad-packs/
>     expire_in: 1 week
> 
> vendor_dependencies:
>   stage: vendor
>   tags:
>     - docker
>   image: hashicorp/nomad-pack:latest
>   dependencies:
>     - prepare_fra_test
>   script:
>     - nomad-pack deps vendor --path=nomad-packs/packs/mypack
>   artifacts:
>     paths:
>       - nomad-packs/packs/mypackp/deps/
>     expire_in: 1 week

the vendor stage exits with this:

`Downloading artifacts  
  00:02` `Downloading artifacts for prepare_fra_test (80792)...` `Downloading artifacts from coordinator... ok        host=git.inatec.com id=80792 responseStatus=200 OK token=glcbt-64 ` ` Executing "step_script" stage of the job script  
  00:01` `Using docker image sha256:c83fa31b55f1ec9b4fd21ba327963d285cab106aabca5ee2cb034d155e1aadbe for hashicorp/nomad-pack:latest with digest hashicorp/nomad-pack@sha256:f6522bcdb2091c0f406921583ac4d2b2ac3698d43c9eabcc2a67c77567b02c02 ...` `Welcome to Nomad Pack` `Docs: ` `Version: v0.1.2 (77dad21)` `Usage: nomad-pack [--version] [--help] [--autocomplete-(un)install] <command> [args]` `Common commands` `  plan         Dry-run a pack update to determine its effects` `  render       Render the templates within a pack` `  run          Run a new pack or update an existing pack` `  destroy      Delete an existing pack` `  info         Get information on a pack` `  status       Get information on deployed packs` `  ` `Other commands` `  deps          Manage dependencies for pack.` `  generate      Generate a sample nomad-pack registry, pack, or variable overrides file for a pack.` `  list          List packs available in the local environment.` `  registry      Add, delete, or list registries and packs in the local environment.` `  stop          Stop a running pack` `  version       Prints the version of Nomad Pack` `   ` ` Cleaning up project directory and file based variables  
  00:00` `ERROR: Job failed: exit code 127`

Not sure what I am doing wrong or if it is correct? the nomad-pack docker image works locally too without any issues. Any help here would be greatly appreciated