Bug 1412050
| Summary: | [platformmanagement_public_852]RreferencePolicy type: Source/Local requires to provide options parameters in command | ||
|---|---|---|---|
| Product: | OKD | Reporter: | ge liu <geliu> |
| Component: | Image Registry | Assignee: | Michal Fojtik <mfojtik> |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | Wei Sun <wsun> |
| Severity: | low | Docs Contact: | |
| Priority: | low | ||
| Version: | 3.x | CC: | aos-bugs, mfojtik |
| Target Milestone: | --- | Keywords: | RFE |
| Target Release: | 3.x | ||
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Enhancement | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2017-05-30 12:48:45 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
ge liu
2017-01-11 04:38:45 UTC
Kudos to @mfojtik. Verified in env:
# openshift version
openshift v1.5.0-alpha.2+98ad752-493
kubernetes v1.5.2+43a9be4
etcd 3.1.0
# oc tag -h
Tag existing images into image streams
.......................
...........
--reference-policy='source': Allow to request pull-trough for external image when set to 'local'. Defaults to 'source'.
..............
# oc tag --source=docker openshift/deployment-example deployment-example:latest --reference-policy='local'
Tag deployment-example:latest set to openshift/deployment-example.
# oc get is
NAME DOCKER REPO TAGS UPDATED
deployment-example 172.30.238.137:5000/lgproj/deployment-example latest 43 seconds ago
[root@ip-172-18-8-87 master]# oc get is deployment-example -o yaml
apiVersion: v1
kind: ImageStream
.................
....
referencePolicy:
type: Local
status:
# oc new-app --image-stream=deployment-example:latest
# oc get dc deployment-example -o yaml
apiVersion: v1
kind: DeploymentConfig
.........
spec:
containers:
- image: 172.xx.xx.xx:5000/lgproj/deployment-example@sha256:ea9135488f323060cb18ab3ec06286cd49e4b3a611fce1a6a442651ecf421f99
imagePullPolicy: Always
................
Regarding to the doc, there are several typo with 'pull-trough':
oc_by_example_content.adoc: line 2941 # Tag an external Docker image and request pull-trough for it.
docs/man/man1/oc-tag.1: line 44 Allow to request pull\-trough for external image when set to 'local'.
line 143 # Tag an external Docker image and request pull\-trough for it.
pkg/cmd/cli/cmd/tag.go: line 70 # Tag an external Docker image and request pull-trough for it.
line 105 "Allow to request pull-trough for external image when set
The option added to 'oc tag', if fixed the dc, but also need to add the option to 'import-image' to fix bc issue, so I opened a new bug to trace this situation: https://bugzilla.redhat.com/show_bug.cgi?id=1420976 and the doc issues in comment 4, I will verified it all together with bug 1420976 |