Skip to content

[Feature Request] Fetch templates from configuration first #927

Open
@vnourdin

Description

Expected Behaviour

When running faas-cli up with no template dir, it should fetch templates configured in the stack.yml before fetching official ones.

Current Behaviour

Fetch first from https://github.com/openfaas/templates.git then from configuration.

Why do you need this?

I work with a custom template, shared across projects, so it is hosted on a git repo.
Thus, I need to pull it from my CI/CD in every project.
Currently, if I run faas-cli up it pulls every official template for nothing. It doesn't take a lot of time, but it's wasting network and CI/CD resources.

Are you a GitHub Sponsor

No

Possible Solution

Fetch first configuration and check if all templates used are here before getting the "default" ones.

Workaround

I currently run faas-cli template pull to only pull my template, before running up.
But I would find it more logical if up pull automatically configured templates before default ones.

Your Environment

  • FaaS-CLI version: 0.14.6

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions