Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

odo init non-interactive mode: Allow specifying ports when Devfile has at most one container component #6919

Closed
4 tasks
kadel opened this issue Jun 21, 2023 · 6 comments
Labels
area/init Issues or PRs related to `odo init` kind/user-story An issue of user-story kind needs-triage Indicates an issue or PR lacks a `triage/*` and requires one. priority/High Important issue; should be worked on before any other issues (except priority/Critical issue(s)).
Milestone

Comments

@kadel
Copy link
Member

kadel commented Jun 21, 2023

/kind user-story

User Story

As an odo user, I want to be able to set the ports when calling odo init non-interactively So that I can have my Devfile initialized right away with the right ports without having to edit it later on.

#5863 added the ability to automatically detect my application ports from the source code and use that as ports when initializing a Devfile interactively, but as a user, I also want to be able to specify such port(s) non-interactively.
This is useful to support the port detection feature in the IDE extensions as well (redhat-developer/vscode-openshift-tools#2781).

As discussed in #6211 (comment), there might be issues with Devfiles that have more than one container components, but this issue will be addressed in #6264.

The goal of this issue is to handle the case where the Devfile has only one container component, which should cover most of the Devfile stacks in the default registry.

Acceptance Criteria

  • [ ] odo init shoudl have paramersts to allow overriding ports in the devfile
  • [ ] to know in which container the port shoudl be added odo init should take an optional argument command-name
  • It should expose a repeatable --port flag, which would allow users to specify several ports
  • It should error out if the Devfile has more than one container components
  • It should ignore the ports definition if the Devfile does not have any container component
  • It should overwrite the endpoints definition with the ones coming from the --port flag
    • [Q] what to do with any debug or debug-* ports?

Links

/kind user-story

@github-actions github-actions bot added the needs-triage Indicates an issue or PR lacks a `triage/*` and requires one. label Jun 21, 2023
@openshift-ci openshift-ci bot added the kind/user-story An issue of user-story kind label Jun 21, 2023
@kadel
Copy link
Member Author

kadel commented Jun 22, 2023

/duplicate
#4448

@kadel
Copy link
Member Author

kadel commented Jun 22, 2023

/triage duplicate

@openshift-ci openshift-ci bot added the triage/duplicate Indicates an issue or PR that is a duplicate of other open issue or PR. label Jun 22, 2023
@kadel
Copy link
Member Author

kadel commented Jun 22, 2023

/close

@openshift-ci
Copy link

openshift-ci bot commented Jun 22, 2023

@kadel: Closing this issue.

In response to this:

/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci openshift-ci bot closed this as completed Jun 22, 2023
@github-project-automation github-project-automation bot moved this to Done ✅ in odo Project Jun 22, 2023
@rm3l rm3l reopened this Jun 22, 2023
@github-project-automation github-project-automation bot moved this from Done ✅ to To Do 📝 in odo Project Jun 22, 2023
@rm3l rm3l changed the title odo init --port odo init --port: Single container component scenario Jun 22, 2023
@rm3l rm3l removed the status in odo Project Jun 22, 2023
@rm3l rm3l added this to the v3.13.0 🚀 milestone Jun 22, 2023
@rm3l rm3l removed the triage/duplicate Indicates an issue or PR that is a duplicate of other open issue or PR. label Jun 22, 2023
@rm3l
Copy link
Member

rm3l commented Jun 22, 2023

After a discussion with Tomas, re-opened the issue and scoped it to handling only the single container component scenario.
The multi-container components scenario will be addressed in #6264

@rm3l rm3l added priority/High Important issue; should be worked on before any other issues (except priority/Critical issue(s)). area/init Issues or PRs related to `odo init` labels Jun 22, 2023
@rm3l rm3l changed the title odo init --port: Single container component scenario odo init non-interactive mode: Allow specifying ports when Devfile has at most one container component Jun 22, 2023
@rm3l
Copy link
Member

rm3l commented Jun 22, 2023

Grooming (2023-06-22)

Closed in favor of #6925

@rm3l rm3l closed this as not planned Won't fix, can't repro, duplicate, stale Jun 22, 2023
@github-project-automation github-project-automation bot moved this to Done ✅ in odo Project Jun 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/init Issues or PRs related to `odo init` kind/user-story An issue of user-story kind needs-triage Indicates an issue or PR lacks a `triage/*` and requires one. priority/High Important issue; should be worked on before any other issues (except priority/Critical issue(s)).
Projects
Archived in project
Development

No branches or pull requests

2 participants