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

Resuse existing imagestreams with new-app #20052

Merged
merged 1 commit into from
Jun 21, 2018
Merged

Resuse existing imagestreams with new-app #20052

merged 1 commit into from
Jun 21, 2018

Conversation

@openshift-ci-robot openshift-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jun 21, 2018
@coreydaley
Copy link
Member Author

@coreydaley
Copy link
Member Author

/retest

@openshift-ci-robot openshift-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jun 21, 2018
@coreydaley
Copy link
Member Author

@openshift/sig-developer-experience ptal

@coreydaley
Copy link
Member Author

/retest

@gabemontero
Copy link
Contributor

Curious if the reuse is obvious or at least discernible from the oc new-app output.... suppose the question of whether it should be obvious/discernible is also valid.

@coreydaley - can you provide sample output from the consecutive invocations like in the card description, or duplicating your cmd.sh test from the command line, so we can review that as well?

thanks

@bparees
Copy link
Contributor

bparees commented Jun 21, 2018

Curious if the reuse is obvious or at least discernible from the oc new-app output.... suppose the question of whether it should be obvious/discernible is also valid.

good point @gabemontero. We already reuse imagestreams for output targets (I believe?), so the experience in terms of message output should mirror that.

@coreydaley
Copy link
Member Author

@bparees @gabemontero ptal

Sample command output:

$ oc new-build -D $'FROM node:8\nRUN echo "Test"' --name=node8
--> Found Docker image 6f1597c (8 hours old) from Docker Hub for "node:8"

    * An image stream will be created as "node:8" that will track the source image
    * A Docker build using a predefined Dockerfile will be created
      * The resulting image will be pushed to image stream "node8:latest"
      * Every time "node:8" changes a new build will be triggered

--> Creating resources with label build=node8 ...
    imagestream "node" created
    imagestream "node8" created
    buildconfig "node8" created
--> Success
    Build configuration "node8" created and build triggered.
    Run 'oc logs -f bc/node8' to stream the build progress.
$ oc get is
NAME      DOCKER REPO                       TAGS      UPDATED
node      172.30.1.1:5000/myproject/node    8         5 seconds ago
node8     172.30.1.1:5000/myproject/node8
$ oc new-build -D $'FROM node:10\nRUN echo "Test"' --name=node10
--> Found Docker image 8753ede (8 hours old) from Docker Hub for "node:10"

    * An image stream will be created as "node:10" that will track the source image
    * A Docker build using a predefined Dockerfile will be created
      * The resulting image will be pushed to image stream "node10:latest"
      * Every time "node:10" changes a new build will be triggered

--> Creating resources with label build=node10 ...
    imagestreamtag "node:10" created
    imagestream "node10" created
    buildconfig "node10" created
--> Success
    Build configuration "node10" created and build triggered.
    Run 'oc logs -f bc/node10' to stream the build progress.
$ oc get is
NAME      DOCKER REPO                        TAGS      UPDATED
node      172.30.1.1:5000/myproject/node     10,8      2 seconds ago
node10    172.30.1.1:5000/myproject/node10             
node8     172.30.1.1:5000/myproject/node8

@bparees
Copy link
Contributor

bparees commented Jun 21, 2018

An image stream will be created as "node:10" that will track the source image

let's just change that to always say "imagestream tag" which is more accurate. (even in the first run).

@coreydaley
Copy link
Member Author

@bparees updated in latest push

@bparees
Copy link
Contributor

bparees commented Jun 21, 2018

@coreydaley take off the wip

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Jun 21, 2018
@openshift-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: bparees, coreydaley

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 21, 2018
@coreydaley coreydaley changed the title [WIP] resuse existing imagestreams with new-app Resuse existing imagestreams with new-app Jun 21, 2018
@openshift-ci-robot openshift-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jun 21, 2018
@openshift-merge-robot openshift-merge-robot merged commit c8924fa into openshift:master Jun 21, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. sig/developer-experience size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants