odo: self linking of the component should not be there using odo link
[kind/bug]
What versions of software are you using?
- Operating System: macOS
- Output of
odo version
: odo v0.0.16 (82968cb0)
How did you run odo exactly?
Running odo from the binary.
Actual behavior
If I do odo link
on the component and pass the same component name in the --component parameter, it works.
e.g. odo link nodejs --component nodejs
Expected behavior
We should handle this condition and make sure that self linking of the component is not allowed or a warning is shown.
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 15 (8 by maintainers)
Commits related to this issue
- Forbid the creation of a link that would link a component to itself Fixes: #1052 — committed to geoand/odo by geoand 6 years ago
- Forbid the creation of a link that would link a component to itself Fixes: #1052 — committed to geoand/odo by geoand 6 years ago
- Forbid the creation of a link that would link a component to itself Fixes: #1052 — committed to geoand/odo by geoand 6 years ago
- Forbid the creation of a link that would link a component to itself Fixes: #1052 — committed to geoand/odo by geoand 6 years ago
@mohitsuman this has been fixed by https://github.com/openshift/odo/pull/4777.
@mohitsuman I’m adding this to our team discussion. Mainly because this is something we need to discuss for odo v2 as well even though this issue was opened for v1.