How a team can work on the same cloud application

10/2/2019

Consider two or more applications "talking" to each other and deployed to the cloud (cloud foundry). What are the best practices for a team to follow to work (develop/test/debug) on the same instance of the applications but in his/her "own" space without creating another instance of the application in the cloud? Or should every developer need to have a local copy of those application and run it in a docker/kubernetes, for example?

-- Tomer
cloud
cloudfoundry
devops
docker
kubernetes

2 Answers

10/6/2019

Your question looks very wide because each business has its own toolchain or way of working. But if you are new and want quickly to organise your team, you can use JX. Jenkins X this is the improved version of Jenkins. JX is supported on Cloud Foundry.

Basically with JenkinsX you have a Preview Environment / Staging / Production. enter image description here

Jenkins X will create automatically the necessary code (helm Charts) to deploy your application to the Cloud... via command

jx import --branches "master|develop"

Give it time, learn it and you will see the magic).

Best practices will be to create a fully CI/CD workflow and to let your team to checkout to the source code at least daily(depending on how many people working on an application).

Good Luck!

-- Valentin
Source: StackOverflow

10/7/2019

The question is broad, but there are some directions that are worth mentioning here. So, a short answer might be:

  1. Run the collaborating apps whenever necessary alongside the app(s) you are developing.
  2. To ease this, prefer CF Local (lightweight Docker containers) over CF Dev (running a whole CF foundation).
  3. If running the other collaborating apps is too much of a challenge, create mocks that mimics their behaviors, for the interactions (or the tests scenarios) you need.

Some words about CF Local: nowadays Cloud Foundry developers are no more recommended to run a whole Cloud Foundry foundation on their laptop anymore. When CF Dev arrived, it was already an improvement for running a whole foundation over BOSH-Lite (that still has its use-cases, I use it everyday), but for a typical cf push developer experience, CF Local fits well and is even more lightweight.

So, CF Local is now recommended instead. It should help you run a bunch of collaborating micro-services applications on your local machine, within standard Docker containers, running on top of a plain Docker engine. For more information, see the CF Local Github page, and the comparison chart with CF Dev about use-cases for which CF Local is a good fit.

For data services (e.g. MySQL or PostgreSQL database), CF Local already provides solutions to re-use the same services instances from your CF foundation. You may also run you own engine on your laptop, and find a way for your cf-local-pushed app to bind to these services in this context.

Hope this might give you some interesting directions in which you can dig and find your way!

-- Benjamin Gandon
Source: StackOverflow