This is our demo.parca.dev cluster configuration.
- argocd -
- argocd-applications -
- cert-manager -
- cluster-config -
- flux -
- grafana -
- ingress-nginx -
- monitoring -
- oauth2-proxy -
- parca -
- parca-devel -
Ask in one of our channels to be invited to the Scaleway Organization. Once you have access you can download the kubeconfig via the UI.
.
├── README.md
└── <application>/ # Kubernetes resources configuration of an appliciation
All the manifest outputs can be passed to kubectl
, example:
${COMMAND} | kubectl diff --namespace "${NAMESPACE}" --filename -
Our strongly opinionated order of preference:
- preferred upstream method (must be 1st class, not derived from another. If more than 1, follow our order of preference)
- Kustomize
- Jsonnet
- Helm
Environment names are generally <cluster_name>
or <cluster_name>-<instance>
.
${APPLICATION}/
├── base/ # Common resources
│ ├── kustomization.yaml
│ ├── resource1.yaml
│ ...
│ └── resourceN.yaml
├── components/
│ └── ${FEATURE}/ # Optional feature resources and overrides
│ ├── kustomization.yaml
│ ├── resource1.yaml
│ ...
│ └── resourceN.yaml
└── overlays/
└── ${ENVIRONMENT}/ # Environment-specific resources and overrides
├── kustomization.yaml
├── extra-resource1.yaml
...
└── extra-resourceN.yaml
Build manifest locally:
cd "${APPLICATION}/overlays/${ENVIRONMENT}"
kustomize build
Requires Kustomize.
${APPLICATION}/
├── environements/
│ └── ${ENVIRONMENT}/ # Environment-specific resources and overrides
│ ├── main.jsonnet # Jsonnet "entrypoint" file
│ └── spec.json # Tanka environment configuration
├── lib/ # Jsonnet libraries
├── vendor/ # Third-party libraries
├── jsonnetfile.json # Jsonnet-bundler dependency tracking
└── jsonnetfile.lock.json # Jsonnet-bundler dependency lock file
Build manifest locally:
cd "${APPLICATION}"
jb install # optional, 3rd-party libraries are checked in Git
jsonnet -J vendor -J lib "environments/${ENVIRONMENT}/main.jsonnet"
Requires Jsonnet and jsonnet-bundler.
Or with Tanka:
tk show "environments/${ENVIRONMENT}"
Requires Tanka.
${APPLICATION}/
├── Chart.lock
├── Chart.yaml
├── values.yaml # Common values
└── values/
└── ${ENVIRONMENT}.yaml # Environment-specific values and overrides
Build manifest locally:
cd "${APPLICATION}/"
helm dependency build
helm template "${RELEASE_NAME}" --namespace "${NAMESPACE}" . \
--values values/${ENVIRONMENT}.yaml
Requires Helm.
Manifests validation is performed by kubeconform.
JSON schemas are extracted from custom resource definitions under .schemas/
.
Edit .schemas/Makefile
to update them and use make -C .schemas
to re-generate them.
Validation can be performed by passing the manifest output to kubeconform
:
${COMMAND} | kubeconform \
-schema-location '.schemas/{{ .ResourceKind }}{{ .KindSuffix }}.json' \
-schema-location 'https://raw.githubusercontent.com/yannh/kubernetes-json-schema/master' \
-skip CustomResourceDefinition \
-strict
- Our Argo CD instance is available at: https://argocd.parca.dev (see also argocd/)
- Argo CD Applications are configured under argocd-applications/
- Flux is used to automate the Parca server and agent image updates (see flux/)
- Renovate is used to update community dependencies (see GitHub App and renovate.json)