Skip to content

Make optional components/directory  #52

@akranga

Description

@akranga

Today hubctl always requires user to specify component source directory like the following:

components:
- name: nginx
  source:
    dir: components/nginx
    git:
      remote: https://github.com/epam/hub-kubeflow-components.git
      subDir: nginx-ingress

We need to allow hubctl to tolerate following syntax:

components:
- name: nginx
  source:
    git:
      remote: https://github.com/epam/hub-kubeflow-components.git
      subDir: nginx-ingress

This means user wants to take component from git repo, but doesn't want to maintain it. In this case expected behaviour, hubctl (or extension) should fetch component to the disposable directory. Probably $HUB_BASE_DIR/.hub. Version of the component should be managed by git/ref when component is a commit sensitive.

When user decided to make their copy of the component they can add source/dir parameter. In this case hubctl (or extension) should not check if component remotely has been updated.

At the present with current design suggesting to declare reason to refresh components in the Hubfile

extensions:
  deploy:
    configure:
    - components.    # to refresh on configure
    before: 
    - components.    # to refresh on pre-deploy action

If above not defined then the component is not fetched and hubctl works as today

  • Create is a components extension to manage this behaviour
  • Move component fetch from hub-init to the new extension
  • Update hubctl to tolerate behaviour in hubctl elaborate
  • Update documentation

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions