<p>I have configured my project to run on a pipeline
Here is my .git.yml file content:</p>

<pre class="lang-yaml prettyprint-override"><code>image: markhobson/maven-chrome:latest

stages:
  - flow1

execute job1:
  stage: flow1
  tags:
    - QaFunctional
  script:
    - export
    - set +e -x
    - mvn --update-snapshots --define updateResults=${updateResults}  clean test
</code></pre>

<p>Error after executing the pipeline :</p>

<pre><code>bash: line 328: mvn: command not found
Running after_script
00:00
Uploading artifacts for failed job
00:00
ERROR: Job failed: exit status 127
</code></pre>

<p>Can anyone help me spot the error please ?
Is that not able to load the  docker image?
When I use a shared runner I am able to execute the same.</p>

user2852305
<p>Error you get means there is no maven installed on job executor <code>mvn: command not found</code></p>

<p>Looks like image you specified <code>image: markhobson/maven-chrome:latest</code> has maven command:</p>

<pre class="lang-sh prettyprint-override"><code># docker run markhobson/maven-chrome:latest mvn --version
Apache Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)
</code></pre>

<p>Other thing you specified is <a href="https://docs.gitlab.com/ee/ci/yaml/#tags" rel="nofollow noreferrer"><code>tags</code></a>:</p>

<pre class="lang-yaml prettyprint-override"><code>...
  tags:
    - QaFunctional
...
</code></pre>

<p>So when both <code>image</code> and <code>tags</code> are specified in your yaml then <code>tags</code> takes precedence and <code>image</code> is ignored.</p>

<p>Looks like your custom runner tagged with <code>QaFunctional</code> is shell runner without mvn configured.</p>

<p>As a solution either install mvn on <code>QaFunctional</code> or run job on docker runner (shared runners should do). To avoid such confusion don't specify <code>image</code> when you want to run your job on tagged shell runner.</p>
