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

fix(builder): print buildpack output, decrease verbosity #60

Merged
merged 1 commit into from
Dec 18, 2015

Conversation

gabrtv
Copy link
Member

@gabrtv gabrtv commented Dec 18, 2015

Replaces #59.

@gabrtv
Copy link
Member Author

gabrtv commented Dec 18, 2015

Note we still need to cleanup extraneous mc output from slugbuilder.

kubectl --namespace=$POD_NAMESPACE create -f /etc/${SLUG_NAME}.yaml >/dev/null

# wait for pod to be running and then pull its logs
until [ "`kubectl --namespace=$POD_NAMESPACE get pods -o yaml ${META_NAME} | grep "phase: " | awk {'print $2'}`" == "Running" ]; do
Copy link
Member

Choose a reason for hiding this comment

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

print something here to indicate that we've started the build?

Copy link
Member

Choose a reason for hiding this comment

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

That $POD_NAMESPACE and $META_NAME are living dangerously without double quotes around them... but I see lots of other problems in this file. So I'm just going to run away and say this looks good to MEEEEeeeeee...

Copy link
Member

Choose a reason for hiding this comment

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

@sgoings I'd love you to crush this file with some bash-fu. Feel free to do so (for beta)!

Copy link
Member

Choose a reason for hiding this comment

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

I, too, like to live dangerously.
dangerously

Copy link
Member

Choose a reason for hiding this comment

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

@gabrtv wants to see it written in !shell which I think is a good idea especially since we could integrate with kubernetes apis here for better? success?

Copy link
Member

Choose a reason for hiding this comment

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

Yes, this will be rewritten in Go soon: #29

@arschles
Copy link
Member

testing locally...

@sgoings
Copy link
Member

sgoings commented Dec 18, 2015

Closes #58

@arschles
Copy link
Member

@gabrtv this looks to effectively stream logs from slugbuilder, but it still shows mc output (see below). I think the problem is that both stdout and stderr are streamed across the SSH conn at https://github.com/deis/builder/blob/master/pkg/git/git.go#L162-L163. Thoughts on piping mc output to /dev/null for now?

ENG000656:example-go aaronschlesinger$ echo "asd" >> README.md && git commit -a -m "Asd" && git push deis master
[master 66112e3] Asd
 1 file changed, 1 insertion(+)
Counting objects: 267, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (122/122), done.
Writing objects: 100% (267/267), 3.02 MiB | 0 bytes/s, done.
Total 267 (delta 146), reused 241 (delta 131)
mc: Configuration written to [/var/minio-conf/config.json]. Please update your access credentials.
mc: Successfully created ‘/var/minio-conf/share’.
mc: Initialized share uploads ‘/var/minio-conf/share/uploads.json’ file.
mc: Initialized share downloads ‘/var/minio-conf/share/downloads.json’ file.
Added host ‘http://10.3.0.121:9000’ successfully.
mc: <ERROR> Unable to make bucket ‘http://10.3.0.121:9000/git’. The requested bucket name is not available.
‘nested-underdog.tar.gz’ -> ‘http://10.3.0.121:9000/git/home/nested-underdog:git-66112e38/tar’
Total: 2.97 MB, Transferred: 2.97 MB, Speed: 31.80 MB/s
.8TZRY2JRWMPT6UMXR6I5 gbstrOvotMMcg2sMfGUhA5a6Et/EI5ALtIHsobYk 10.3.0.121:9000
mc: Configuration written to [/app/mc_config/config.json]. Please update your access credentials.
mc: Successfully created ‘/app/mc_config/share’.
mc: Initialized share uploads ‘/app/mc_config/share/uploads.json’ file.
mc: Initialized share downloads ‘/app/mc_config/share/downloads.json’ file.
Added host ‘http://10.3.0.121:9000’ successfully.
‘http://10.3.0.121:9000/git/home/nested-underdog:git-66112e38/tar’ -> ‘/tmp/slug.tgz’
Total: 2.97 MB, Transferred: 2.96 MB, Speed: 62.69 MB/s
8TZRY2JRWMPT6UMXR6I5 gbstrOvotMMcg2sMfGUhA5a6Et/EI5ALtIHsobYk 10.3.0.121:9000
mc: Configuration written to [/app/mc_config/config.json]. Please update your access credentials.
mc: Successfully created ‘/app/mc_config/share’.
mc: Initialized share uploads ‘/app/mc_config/share/uploads.json’ file.
mc: Initialized share downloads ‘/app/mc_config/share/downloads.json’ file.
Added host ‘http://10.3.0.121:9000’ successfully.
‘http://10.3.0.121:9000/git/home/nested-underdog:git-66112e38/tar’ -> ‘/tmp/slug.tgz’
Total: 2.97 MB, Transferred: 2.96 MB, Speed: 62.69 MB/s
-----> Go app detected

@gabrtv
Copy link
Member Author

gabrtv commented Dec 18, 2015

@arschles hmm i'm not seeing all of that output, but I agree we can shift output to /dev/null for now. I know a lot of that output is from slugbuilder. One sec..

@gabrtv
Copy link
Member Author

gabrtv commented Dec 18, 2015

Shifted some stuff to /dev/null. Here is the new output. I'm almost positive the mc debug you see is coming from slugbuilder:

$ git push deis master
Counting objects: 1, done.
Writing objects: 100% (1/1), 178 bytes | 0 bytes/s, done.
Total 1 (delta 0), reused 0 (delta 0)
.8TZRY2JRWMPT6UMXR6I5 gbstrOvotMMcg2sMfGUhA5a6Et/EI5ALtIHsobYk 10.199.243.237:9000
mc: Configuration written to [/app/mc_config/config.json]. Please update your access credentials.
mc: Successfully created ‘/app/mc_config/share’.
mc: Initialized share uploads ‘/app/mc_config/share/uploads.json’ file.
mc: Initialized share downloads ‘/app/mc_config/share/downloads.json’ file.
Added host ‘http://10.199.243.237:9000’ successfully.
‘http://10.199.243.237:9000/git/home/node:git-728022b9/tar’ -> ‘/tmp/slug.tgz’
Total: 2.52 KB, Transferred: 0 B, Speed: 0 B/s
-----> Node.js app detected

-----> Creating runtime environment

       NPM_CONFIG_LOGLEVEL=error
       NPM_CONFIG_PRODUCTION=true
       NODE_ENV=production
       NODE_MODULES_CACHE=true

-----> Installing binaries
       engines.node (package.json):  0.12.x
       engines.npm (package.json):   unspecified (use default)

       Resolving node version 0.12.x via semver.io...
       Downloading and installing node 0.12.9...
       Using default npm version: 2.14.9

-----> Restoring cache
       Skipping cache (new runtime signature)

-----> Building dependencies
       Pruning any extraneous modules
       Installing node modules (package.json)
       express@3.1.2 node_modules/express
       ├── methods@0.0.1
       ├── fresh@0.1.0
       ├── range-parser@0.0.4
       ├── cookie-signature@1.0.0
       ├── buffer-crc32@0.2.5
       ├── cookie@0.0.5
       ├── commander@0.6.1
       ├── mkdirp@0.3.5
       ├── debug@2.2.0 (ms@0.7.1)
       ├── send@0.1.0 (mime@1.2.6)
       └── connect@2.7.5 (pause@0.0.1, bytes@0.2.0, buffer-crc32@0.1.1, formidable@1.0.11, qs@0.5.1)

-----> Caching build
       Clearing previous node cache
       Saving 1 cacheDirectories (default):
       - node_modules

-----> Build succeeded!
       └── express@3.1.2

-----> Discovering process types
       Procfile declares types -> web
       Default process types for Node.js -> web
-----> Compiled slug size is 9.8M
8TZRY2JRWMPT6UMXR6I5 gbstrOvotMMcg2sMfGUhA5a6Et/EI5ALtIHsobYk 10.199.243.237:9000
Added host ‘http://10.199.243.237:9000’ successfully.
‘/tmp/slug.tgz’ -> ‘http://10.199.243.237:9000/git/home/node:git-728022b9/push/slug.tgz’
Total: 9.71 MB, Transferred: 9.71 MB, Speed: 32.35 MB/s
-----> Launching... 
       done, node:v19 deployed to Deis

       http://node.localhost

       To learn more, use `deis help` or visit http://deis.io

To ssh://git@deis.gabrtv.io:2222/node.git
   186d974..728022b  master -> master

@arschles arschles added the LGTM2 label Dec 18, 2015
@arschles
Copy link
Member

@gabrtv alrighty. gave them LGTM for this then.

gabrtv pushed a commit that referenced this pull request Dec 18, 2015
fix(builder): print buildpack output, decrease verbosity
@gabrtv gabrtv merged commit daac4b8 into deis:master Dec 18, 2015
@gabrtv gabrtv deleted the fix-output branch December 18, 2015 19:11
yebyen pushed a commit to yebyen/builder that referenced this pull request Jan 12, 2020
chore(go-dev): move to image fork hephy/go-dev:v1.25.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants