DEPRICATED - use https://github.com/codefresh-io/kcfi for installing Codefresh on Kubernetes
cf-onprem
- script that deploys Codefresh application on any kubernetes cluster
cf-onprem
script reads default variables and environment variables that can override defaults, validates and approves current cluster context, checks if helm
binary is installed, installs helm
binary, deploys codefresh
chart with helm
.
Before running cf-onprem
script it is needed to:
- override default environment variables in
env-vars
file if needed - make configuration changes specific for each customer
There are three files that customize codefresh
chart deployment:
values.yaml.tpl
contains template of values.yaml for different parameters for chart customization
- Clone onprem repository
git clone [email protected]:codefresh-io/onprem.git
cd onprem
-
cp
values.yaml.tpl
values.yaml
-
Edit values.yaml Mandatory to set
global.appUrl
andfirebaseToken
Codefresh can run on local volumes - https://kubernetes.io/docs/concepts/storage/volumes/#local To create local volumes edit `local-volumes/values.yaml`, set: - defaultNodeSelector - mkdirPods.nodes then run `local-volumes/create-local-pvcs.sh` edit values.yaml and set the values for `existingPvc`s
-
Web SSL Certificates installer configures ingress tls patameters accorfing to "tls" key in values.yaml
# default values
tls:
selfSigned: false
cert: certs/ssl.crt
key: certs/private.key
if ssl.selfSigned=false (default) installer validates and uses values of ssl.cert and ssl.key. Certifaicate and key files should exist in the specified location. Otherwise if ssl.selfSigned=true it generates selfsigned certificates with CN=<global.appUrl>
- run Intaller:
./cf-onprem [parameters]
Example 1 - from dev repo channel specific version :
./cf-onprem --tiller-namespace codefresh --repo-channel dev --version 1.0.90
Example 2 - from downloaded helm chart with private registry and downloaded helm
helm repo add codefresh-onprem-dev http://charts.codefresh.io/dev
helm fetch codefresh-onprem-dev/codefresh
./cf-onprem --tiller-namespace codefresh --helm-chart codefresh-1.0.90.tgz --reg-user admin --reg-password <password> --private-registry docker-local.jfrog1.cf-cd.com/
Example 3: - rerun jobs
./cf-onprem --set global.seedJobs=true --set global.certsJobs=true
Download the chart using helm fetch
and then run cf-onprem with --do-template and --helm-chart
helm fetch --repo http://charts.codefresh.io/test codefresh --version 1.0.104-k16.tgz
./cf-onprem --do-template --helm-chart /Users/user/devel/cf-helm/codefresh-1.0.104-k16.tgz
Find producted output in out/
directory
On first run the installers invokes Validator chart which validates:
- values.yaml
- ability to launch persistent services on specified storage classes
- ability to launch persistent services on specified existing pvcs
the validator can be run separately by ./run-validator.sh