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

Add Trusted (Yes/No) output to inspect-builder #697

Merged
merged 1 commit into from
Jun 16, 2020

Conversation

simonjjones
Copy link
Member

Signed-off-by: Simon Jones [email protected]

Summary

pack inspect-builder <builder-name> now includes an additional output line called Trusted that indicates whether pack will treat the named builder as trusted. In practice right now, this will indicated whether a pack build command would use the creator lifecycle phase or separate phases.

Output

Before

$ pack inspect-builder heroku/buildpacks:18
Inspecting builder: heroku/buildpacks:18

REMOTE:

Created By:
  Name: Pack CLI
  Version: 0.11.1+git-d69a91f.build-644

Stack:
  ID: heroku-18

Lifecycle:
  Version: 0.7.5
  Buildpack API: 0.2
  Platform API: 0.3

Run Images:
  heroku/pack:18

Buildpacks:
  ID                          VERSION        HOMEPAGE
  heroku/maven                0.1
  heroku/jvm                  0.1
  heroku/java                 0.1
  heroku/ruby                 0.0.1
  heroku/procfile             0.5
  heroku/python               0.2
  heroku/gradle               0.2
  heroku/scala                0.2
  heroku/php                  0.2
  heroku/go                   0.2
  heroku/nodejs-engine        0.4.3
  heroku/nodejs-npm           0.1.4
  heroku/nodejs-yarn          0.0.1
  heroku/nodejs               0.1

Detection Order:
  Group #1:
    heroku/ruby
    heroku/procfile    (optional)
  Group #2:
    heroku/python
    heroku/procfile    (optional)
  Group #3:
    heroku/java
  Group #4:
    heroku/scala
    heroku/procfile    (optional)
  Group #5:
    heroku/php
    heroku/procfile    (optional)
  Group #6:
    heroku/go
    heroku/procfile    (optional)
  Group #7:
    heroku/nodejs
LOCAL:
(not present)

After

$  pack inspect-builder heroku/buildpacks:18
Inspecting builder: heroku/buildpacks:18

REMOTE:

Created By:
  Name: Pack CLI
  Version: 0.11.1+git-d69a91f.build-644

Trusted: Yes

Stack:
  ID: heroku-18

Lifecycle:
  Version: 0.7.5
  Buildpack API: 0.2
  Platform API: 0.3

Run Images:
  heroku/pack:18

Buildpacks:
  ID                          VERSION        HOMEPAGE
  heroku/maven                0.1
  heroku/jvm                  0.1
  heroku/java                 0.1
  heroku/ruby                 0.0.1
  heroku/procfile             0.5
  heroku/python               0.2
  heroku/gradle               0.2
  heroku/scala                0.2
  heroku/php                  0.2
  heroku/go                   0.2
  heroku/nodejs-engine        0.4.3
  heroku/nodejs-npm           0.1.4
  heroku/nodejs-yarn          0.0.1
  heroku/nodejs               0.1

Detection Order:
  Group #1:
    heroku/ruby
    heroku/procfile    (optional)
  Group #2:
    heroku/python
    heroku/procfile    (optional)
  Group #3:
    heroku/java
  Group #4:
    heroku/scala
    heroku/procfile    (optional)
  Group #5:
    heroku/php
    heroku/procfile    (optional)
  Group #6:
    heroku/go
    heroku/procfile    (optional)
  Group #7:
    heroku/nodejs

LOCAL:
(not present)

Documentation

  • Should this change be documented?

Related

Unblocks #670 along with #693

Resolves #669

@simonjjones simonjjones requested a review from a team as a code owner June 16, 2020 19:55
@codecov
Copy link

codecov bot commented Jun 16, 2020

Codecov Report

Merging #697 into master will increase coverage by 0.13%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #697      +/-   ##
==========================================
+ Coverage   72.53%   72.65%   +0.13%     
==========================================
  Files          67       67              
  Lines        4880     4898      +18     
==========================================
+ Hits         3539     3558      +19     
+ Misses       1020     1019       -1     
  Partials      321      321              
Flag Coverage Δ
#os_linux 75.30% <100.00%> (+0.10%) ⬆️
#os_macos 71.40% <100.00%> (+0.07%) ⬆️
#os_windows 71.24% <100.00%> (+0.17%) ⬆️
#unit 72.65% <100.00%> (+0.13%) ⬆️

Copy link
Member

@dfreilich dfreilich left a comment

Choose a reason for hiding this comment

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

LGTM, in general.

I'm unsure whether this needs an acceptance test though, it feels like unit tests for this alone should suffice.

@jromero jromero added this to the 0.12.0 milestone Jun 16, 2020
@jromero jromero added the type/enhancement Issue that requests a new feature or improvement. label Jun 16, 2020
@jromero jromero merged commit 61850a9 into master Jun 16, 2020
@jromero jromero deleted the 669-inspect-builder-shows-trusted branch June 16, 2020 21:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/enhancement Issue that requests a new feature or improvement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

pack when inspecting a builder should show that a builder is trusted
3 participants