title: Specifying a different 'Executed Function' than 'Name' in GCP cloudbuild.yaml
body: <p>How do I specify a different &quot;Executed Function&quot; in my cloudbuild.yaml file than the name of the actual function name in GCP?</p>
  <p>For example:</p>
  <ul>
  <li>I have a cloud function, written in python called <code>hello_world</code></li>
  <li>In my GCP deployment, I want to name the function <code>hello-world-dev</code>, and <code>hello-world-prod</code> which is passed in the Triggers variables dynamically on build.</li>
  <li>Build fails because it was expecting the function to be called <code>hello-world-dev</code> or whatever</li>
  <li>I'm sure there's a flag to specify the executing function, but I haven't found it.</li>
  </ul>
  <p>My <code>cloudbuild.yaml</code> file looks like this:</p>
  <pre><code>#hello-world
    - name: 'gcr.io/google.com/cloudsdktool/cloud-sdk'
      args:
        - gcloud
        - functions
        - deploy
        - hello-world-${_ENV}
        - --region=us-west2
        - --source=./demo/hello-world/
        - --trigger-http
        - --runtime=python39
  </code></pre>
  <p><strong>Steps I've Tried</strong></p>
  <p>I've tried the following flags:</p>
  <ul>
  <li><code>--function</code></li>
  <li><code>--call</code></li>
  <li><code>--deploy</code></li>
  </ul>
  <p>Looking at this documentation: <a href="https://cloud.google.com/functions/docs/deploying" rel="nofollow noreferrer">https://cloud.google.com/functions/docs/deploying</a></p>
  <p><a href="https://i.stack.imgur.com/M4jco.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/M4jco.png" alt="enter image description here" /></a></p>