odo: odo link fails to link components
/kind bug
What versions of software are you using?
Operating System: all supported
Output of odo version:
master
How did you run odo exactly?
Steps:
- Created the nodejs frontend and backend component in two different context. Also specify
--appflag for one of the component - Add url having same name but different port for both the component
- Add storage volume for both.
- Push the components
- Perform
odo linkoperation
I ran the steps manually in regular mode on 4.4 openshift cluster.
Actual behavior
$ odo project create nodejss
✓ Project 'nodejss' is ready for use
✓ New project created and now using project: nodejss
$ cd manualtest/
$ odo create nodejs backend --port 8080,8100/tcp --context . --project nodejss
✓ Validating component [996ms]
Please use `odo push` command to create the component with source deployed
$ odo url create abcd --port 8100 --context .
✓ URL abcd created for component: backend
To create URL on the OpenShift Cluster, please use `odo push`
$ odo storage create pv2 --path /mnt/pv2 --size 1Gi --context .
✓ Added storage pv2 to backend
Please use `odo push` command to make the storage accessible to the component
$ odo push --context .
Validation
✓ Checking component [2s]
Configuration changes
✓ Added storage pv2 to backend
✓ Initializing component
✓ Creating component [5s]
Applying URL changes
✓ URL abcd: http://abcd-app-nodejss.apps.ci-ln-3fsz22k-d5d6b.origin-ci-int-aws.dev.rhcloud.com created
Pushing to component backend of type local
✓ Checking files for pushing [4ms]
✓ Waiting for component to start [1m]
✓ Syncing files to the component [7s]
✓ Building component [15s]
✓ Changes successfully pushed to component
$ odo create nodejs frontend --context ../tests/examples/source/nodejs/ --project nodejss --app testing
✓ Validating component [733ms]
Please use `odo push` command to create the component with source deployed
$ odo url create abcd --port 8080 --context ../tests/examples/source/nodejs/
✓ URL abcd created for component: frontend
To create URL on the OpenShift Cluster, please use `odo push`
$ odo storage create pv1 --path /mnt/pv1 --size 1Gi --context ../tests/examples/source/nodejs/
✓ Added storage pv1 to frontend
Please use `odo push` command to make the storage accessible to the component
$ odo push --context ../tests/examples/source/nodejs/
Validation
✓ Checking component [1s]
Configuration changes
✓ Added storage pv1 to frontend
✓ Initializing component
✓ Creating component [4s]
Applying URL changes
✓ URL abcd: http://abcd-testing-nodejss.apps.ci-ln-3fsz22k-d5d6b.origin-ci-int-aws.dev.rhcloud.com created
Pushing to component frontend of type local
✓ Checking files for pushing [6ms]
✓ Waiting for component to start [34s]
✓ Syncing files to the component [4s]
✓ Building component [10s]
✓ Changes successfully pushed to component
$ odo link backend --port 8080 --context ../tests/examples/source/nodejs/
✗ Neither a service nor a component named backend could be located. Please create one of the two before attempting to use 'odo link'
Expected behavior
odo link should link the component successfully.
Any logs, error output, etc?
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 21 (16 by maintainers)
I tried the same scenario and it works successfully for me now. So closing this issue.