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

Rename generic run-on flag into platform #6438

Closed
wants to merge 14 commits into from

Conversation

feloy
Copy link
Contributor

@feloy feloy commented Dec 23, 2022

What type of PR is this:

/kind feature

What does this PR do / why we need it:

  • rename --run-on flag with --platform
  • change "RUNNING ON" header with "PLATFORM" in output of odo list component
  • duplicate runningOn with platform field in JSON output of odo list component and deprecate runningOn

Which issue(s) this PR fixes:

Fixes #6318

PR acceptance criteria:

  • Unit test

  • Integration test

  • Documentation

How to test changes / Special notes to the reviewer:

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. Required by Prow. label Dec 23, 2022
@netlify
Copy link

netlify bot commented Dec 23, 2022

Deploy Preview for odo-docusaurus-preview canceled.

Name Link
🔨 Latest commit 48c9733
🔍 Latest deploy log https://app.netlify.com/sites/odo-docusaurus-preview/deploys/63a5b44e3c958b0008ce9c36

@openshift-ci openshift-ci bot added the kind/feature Categorizes issue as a feature request. For PRs, that means that the PR is the implementation label Dec 23, 2022
@openshift-ci openshift-ci bot requested review from kadel and rnapoles-rh December 23, 2022 11:09
@odo-robot
Copy link

odo-robot bot commented Dec 23, 2022

OpenShift Tests on commit 0e003df finished successfully.
View logs: TXT HTML

@odo-robot
Copy link

odo-robot bot commented Dec 23, 2022

NoCluster Tests on commit 0e003df finished successfully.
View logs: TXT HTML

@odo-robot
Copy link

odo-robot bot commented Dec 23, 2022

Unit Tests on commit 0e003df finished successfully.
View logs: TXT HTML

@odo-robot
Copy link

odo-robot bot commented Dec 23, 2022

Validate Tests on commit 0e003df finished successfully.
View logs: TXT HTML

@odo-robot
Copy link

odo-robot bot commented Dec 23, 2022

Kubernetes Tests on commit 0e003df finished successfully.
View logs: TXT HTML

@odo-robot
Copy link

odo-robot bot commented Dec 23, 2022

Windows Tests (OCP) on commit 0e003df finished successfully.
View logs: TXT HTML

@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 1 Code Smell

No Coverage information No Coverage information
0.0% 0.0% Duplication

@feloy feloy changed the title [wip] Rename generic run-on flag into platform Rename generic run-on flag into platform Dec 23, 2022
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. Required by Prow. label Dec 23, 2022
@feloy feloy requested review from valaparthvi and removed request for kadel December 23, 2022 14:30
@feloy feloy removed the request for review from rnapoles-rh December 23, 2022 14:30
Copy link
Member

@rm3l rm3l left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a few comments. I also noticed that there were a few changes related to #6437 (odo delete component --name on Podman). Can you rebase this branch onto main instead?

@@ -31,7 +31,7 @@ Learn more about the experimental mode in [this doc](../docs/user-guides/advance
<iframe width="560" height="315" src="https://www.youtube.com/embed/EmN_hGkOHX4?list=PLGMB2PY4SNOr5pjbPTdcWsIrOezCPXWdX" title="odo dev using podman" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>

You can now use`odo dev` to run your application on Podman. `odo` leverages the benefit of Podman to work seamlessly with Kubernetes YAML and replicate them to containers locally.
This is an experimental feature and can be used with `--run-on` flag.
This is an experimental feature and can be used with `--platform` flag.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should keep run-on in this blog post, as it is specific and relevant to 3.3.0

@@ -9,7 +9,10 @@ type ComponentAbstract struct {
RunningIn RunningModes `json:"runningIn"`
Type string `json:"projectType"`
// RunningOn is the platform the component is running on, either cluster or podman
// This field is deprecated and will be replaced by Platform
RunningOn string `json:"runningOn,omitempty"`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you also mark this field as deprecated with the // Deprecated: comment?

// GenericRunOnFlag is the feature supporting the `--run-on` generic CLI flag.
GenericRunOnFlag = OdoFeature{
// GenericPformFlag is the feature supporting the `--platform` generic CLI flag.
GenericPformFlag = OdoFeature{
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few characters missing here - I think you meant GenericPlatformFlag ;-)

Copy link
Member

@rm3l rm3l left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One last comment. Can you also update the following occurrences accordingly?

$ git grep 'run-on' -- ':!docs/website/blog' ':!vendor'

tests/integration/cmd_devfile_list_test.go:                     It("should display component depending on experimental mode and run-on flag", func() {
tests/integration/cmd_devfile_list_test.go:                                     By("returning component not in dev mode when experimental mode is enabled with json output and run-on is cluster", func() {

@feloy
Copy link
Contributor Author

feloy commented Jan 2, 2023

Closed in favor of #6445 (based on main instead of branch)

@feloy feloy closed this Jan 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue as a feature request. For PRs, that means that the PR is the implementation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Rename generic run-on flag into platform
2 participants