Blog

You can become a superhero of automation and development by learning and practicing. This is our blog from our learnings and practice.

We are consultants and trainers in Cloud Foundry, devops automation and continous delivery. We have the best jobs in the world helping you have the best job in the world.

如何调适Cloud Foundry 中的应用?

当你的应用没有正常运行时,你该怎么办? 拜读此篇博客! Stark & Wayne 团队总结了一些在Cloud Foundry (CF) 中调试应用的经验。 日志 日志通常是最好的入手点。应用的任何标准输出或者错误都会在cf log 的输出中得到显示。如果你在cf log输出中没有看到应用的日志,请确保你使用标准输出而不是输出到日志文件。 cf logs <APP> –recent 事件 应用的容器瘫痪,停止工作,重启等都会触发事件。事件在帮助你和日志中的一些内容进行关联方面很有用。 cf events <APP> 在此链接中有几个CF调试的命令行Troubleshooting Application Deployment and Health. 远程登录到 Diego 容器 如果容器开起了SSH特性(可以通过命令行开启),你可以远程登录到Diego容器进行调试。如果你直接进行Docker容器推送(而不是依靠buildpacks), 你可以任意添加你想要的诊断工具,比如strace, lsof, jconsol 等等。 cf ssh <APP> 监控 安装类似MQTT等可以接收度量和日志数的工具会很有用处。比如它可以告诉你当内存在按照一定速率持续增长,不加以处理最重会使容器崩溃。你也可以安装一些应用级别的监控系统,比如DATADOG 和 New Relic。 HTTP跟踪 当你只需要知道应用的CLI与远程的API通信的状况,HTTP跟踪也是一个可用的调试方式。 我们实现了一个叫做gotcha的应用工具,它可以作为一个MiTM代理放在测试单元和远程HTTP终端之间使用。工具本身可以在 starkandwayne/gotcha找到, 如何使用这款工具可以在博客capture-http-requests-to-your-cloud-foundry中找到。 调试不同类型应用的技巧 你运行的应用类型是什么?什么语言?什么架构? 你可能会发现下面的工具很有用。 Java和Ruby 应用 如果你使用Eclipse写Java或者Ruby应用,你可能会在

Dr. Xiujiao Gao 高秀娇 Profile Image

Posted by:
Dr. Xiujiao Gao 高秀娇

Read More ➝
Simple secure credentials into YAML with Vault and Spruce

We use YAML for configuration of many things – Concourse pipelines, BOSH deployments, Cloud Foundry applications, and more. And we continually want to be more secure with how we handle our secrets. Two tools can be used together to help: Hashicorp vault for storing secrets Geoff Franks spruce for merging vault secrets into YAML files.

Ashley Gerwitz Profile Image

Posted by:
Ashley Gerwitz

Read More ➝
Building a Linux Static Binary with sipcalc, CentOS 7, and Docker

First: What is sipcalc? sipcalc is a handy tool that makes networking a bit less painful, e.g.: $ sipcalc 192.168.0.0/24 -[ipv4 : 192.168.0.0/24] – 0 [CIDR] Host address – 192.168.0.0 Host address (decimal) – 3232235520 Host address (hex) – C0A80000 Network address – 192.168.0.0 Network mask – 255.255.255.0 Network mask (bits) – 24 Network mask

Quintessence Anx Profile Image

Posted by:
Quintessence Anx

Read More ➝
Learning to Troubleshoot BOSH using fubar-boshrelease

A short time ago, I created the fubar-boshrelease with the purpose of providing a broken BOSH release that would help expose operators, and developers to various aspects of troubleshooting things going wrong when working with BOSH. It starts out as a BOSH release repo needing to be built, uploaded, deployed, and made to work. However,

GeoffFranks Profile Image

Posted by:
GeoffFranks

Read More ➝
How to Debug Your Apps in Cloud Foundry?

What will you do when your apps are not working?Read this blog! S&W team has summarized some useful tips for debugging apps in Cloud Foundry. Logs Logs are usually the best bet. Anything the application prints to standard output or standard error will show up in the cf logs output for that application. If you

Dr. Xiujiao Gao 高秀娇 Profile Image

Posted by:
Dr. Xiujiao Gao 高秀娇

Read More ➝
BOSH + UAA with Signed Certificates – Part II

In the second part of configuring UAA with BOSH we’ll cover changes which are needed for Health Monitor which may not be obvious from the tutorial found at http://bosh.io/docs/director-users-uaa.html. Part I of this tutorial is here: https://www.starkandwayne.com//blog/bosh-uaa-with-signed-certificates/ Change Health Manager Authentication In your deployment manifest you should have the user and password defined similar to:

Chris Weibel Profile Image

Posted by:
Chris Weibel

Read More ➝
How to Choose a Stemcell

When you need a stemcell for a release, you go to the https://www.bosh.io/stemcells page. While it’s clear which Operating System to choose from (Ubuntu or Cent OS) the next few decisions to make can become less clear as you sort through each of the additional options. In this article, we’ll help you understand what all

Ashley Gerwitz Profile Image

Posted by:
Ashley Gerwitz

Read More ➝
Verify Order of Signed Certificates for UAA + BOSH

In a previous article (https://www.starkandwayne.com//blog/bosh-uaa-with-signed-certificates/) we discovered how to add a multiple/intermediate level signed certificates to UAA on BOSH. Recently I discovered one of my deployments had the certs in the wrong order and a kind gentleman named Thilak showed me how to verify the order of certificates is correct. While the bosh_cli didn’t complain

Chris Weibel Profile Image

Posted by:
Chris Weibel

Read More ➝
bosh-init on AWS, What Time is it Mr. Fox?

We ran into an interesting problem today while running bosh-init against AWS: CPI ‘has_vm’ method responded with error: CmdError{"type":"Unknown","message":"AWS was not able to validate the provided access credentials","ok_to_retry":false} This is a CPI error so after a bit of investigation confirmed our AWS keys were correct and valid with the awscli. After some more digging we

Chris Weibel Profile Image

Posted by:
Chris Weibel

Read More ➝