Question

OpenShift seems to encourage developers to push a repo directly to OpenShift, which is pretty convenient. If an application (using node.js, but that probably doesn't matter much for this question) has mostly public files, but a few private files for things like DB passwords, external api keys, license keys, New Relic config, etc., what is the recommended way of deploying?

One idea that comes to mind is to have 1 public repo, 1 private repo, and a deploy script that puts everything together, commits to a separate private deploy repo, and then push that deploy repo to OpenShift.

This seems like it would be a common use case though, so perhaps the deploy script with extra repo is unnecessary if OpenShift already has a process for this.

Was it helpful?

Solution

The recommended way is to use environment variables for things like db passwords and keys. And unless you are also copying your code to a public github repo, then everything you push to your OpenShift hosted git repo is private to just you.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top