Skip to content

Implement alizer support for devfile port detection #1331

@thepetk

Description

@thepetk

Which area/kind this issue is related to?

/area alizer

Issue Description

This issue part of EPIC #1363 and is focusing on the implementation of devfile port detection function. This task has several steps we should follow:

  • Expand the functionality of utils.GetLocations() to detect locations for devfiles too. The function will follow the some prioritization rules:

    1. First look into the root level and then we will look one level down, exactly like the dockerfile case.
    2. The devfile naming follows specific naming prioritization -> devfile.yaml > .devfile.yaml > devfile.yml > .devfile.yml
  • Implementation of enricher.GetPortsFromDevfile, similar to enricher.GetPortsFromDockerfile which will be using the library's parser.Parse function in order to fetch the ports from the devfile.

  • The function will return either inner loop, or outerloop ports (or both), based on what flag the user passes in.

  • Require user to specify inner loop vs. outerloop ports (or both) when retrieving the ports

Acceptance Criteria

  • The GetPortsFromDevfile is implemented and able to detect ports inside a devfile.y(a)ml.
  • Specific prioritization will be followed for the naming of the devfiles.
  • Test cases are created.
  • Flags to specify inner loop, outerloop or both types of ports
  • Alizer to use Devfile library to parse devfiles

Metadata

Metadata

Assignees

Labels

area/alizerEnhancement or issue related to the alizer repodemoIssue or PR candidate for a demo at the end of the Sprintlifecycle/rottenRotten items. These items have been stale for 60 days and are now closed.lifecycle/staleStale items. These items have not been updated for 90 days.severity/blockerIssues that prevent developers from working

Type

No type

Projects

Status

Done ✅

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions