Compute Options & Infrastructure as Code
Code Engine vs. IKS
Code Engine is fully managed serverless: deploy a container, batch job, or function without managing infrastructure — it scales to zero when idle. IKS (or OpenShift) gives full control over cluster configuration and Kubernetes primitives at the cost of operational overhead. A common pattern: start on Code Engine for simplicity, move to IKS only once workload needs (custom operators, specific K8s APIs) actually demand it.
ibmcloud ce project create --name my-project
ibmcloud ce application create --name my-app \
--image us.icr.io/my-namespace/my-app:1.0 \
--cpu 0.5 --memory 1G --min-scale 0 --max-scale 10
ibmcloud ce jobrun submit --name nightly-report --image us.icr.io/my-namespace/report:1.0Cloud Functions (OpenWhisk)
// action.js — an OpenWhisk action
function main(params) {
return { message: `Hello, ${params.name || 'World'}!` };
}
exports.main = main;
// ibmcloud fn action create hello action.js
// ibmcloud fn action invoke hello --param name Alice --result
// ibmcloud fn api create /hello GET hello --response-type jsonSchematics (Terraform)
# Schematics runs Terraform in a managed workspace — state and locking
# are handled for you, no separate remote-state backend to set up.
ibmcloud schematics workspace new --file workspace.json
ibmcloud schematics plan --id <workspace-id>
ibmcloud schematics apply --id <workspace-id>
# workspace.json points at a Terraform repo, e.g.:
# {
# "name": "my-vpc",
# "template_repo": { "url": "https://github.com/org/my-vpc-terraform" },
# "template_data": [{ "folder": ".", "type": "terraform_v1.5" }]
# }Auditing
Activity Tracker records auditable events across IBM Cloud services — API calls, resource changes, IAM policy modifications — for compliance and security investigation, analogous to AWS CloudTrail or Azure Activity Log.
Keep your own version of these notes — editable, searchable, and organised by your stack.
Start free