Back up Telark
What Telark stores, how to back it up, and how to restore it into a new cluster.
Telark does not back itself up. Choose the tool; this page lists what to capture and the restore order.
What to back up
| Data | Where | Why it matters |
|---|---|---|
Custom resources (telark.io) | etcd, in the telark namespace | Applications and their history, protection plans, settings, users, groups, roles, passkeys. The TelarkConfig status also holds the migration record and the pinned bootstrap account with its break-glass requests. |
Snapshot volume telark-exporter-snapshots-pvc | Mounted by the exporter at /snapshots | Rollback targets: /snapshots/apps/<app>/<namespace>/V<generation>.json |
Reports volume telark-exporter-reports-pvc | Mounted by the exporter at /reports | Protection plan reports and decision ledgers, the only record of a finished plan, and under kept/ the reports kept after their plan was deleted |
A storage class change moves the data to new claims named after the class, such as telark-exporter-snapshots-pvc-efs-sc-rwx. kubectl get pvc -n telark lists the current ones.
Not worth backing up: Redis (in-app notifications, insights, queues and locks; losing it clears the notification feed and current insights, and drops the webhook deliveries still owed) and the Kyverno policies of active plans, which Telark redeploys from the plans.
The snapshot volume holds Secret manifests. Encrypt and restrict its backups accordingly.
1. Back up the volumes
With Velero and CSI volume snapshots, a schedule over the whole namespace captures both volumes and the custom resources in one backup:
apiVersion: velero.io/v1
kind: Schedule
metadata:
name: telark
namespace: velero
spec:
schedule: "0 */6 * * *"
template:
includedNamespaces:
- telark
snapshotVolumes: true
ttl: 720hWithout CSI snapshots, use Velero's file-system backup, or your cloud's volume snapshots (aws ec2 create-snapshot, gcloud compute disks snapshot, az snapshot create).
2. Export the custom resources
For a portable copy, or to inspect objects outside Velero:
for r in applications protectionplans telarkconfigs categories \
users groups accessroles passkeys sessions; do
kubectl get "$r.telark.io" -n telark -o yaml > "$r.yaml"
doneUse the fully qualified names. A plain kubectl get applications may return Argo CD's resources instead.
Restore into a new cluster
-
Install Telark as for a fresh cluster (Install Telark for production), with the same flags.
-
Restore the snapshot and report volumes, then restart the exporter so it mounts them:
kubectl rollout restart -n telark deploy/telark-exporter-service -
Restore the custom resources in this order:
Category,AccessRole,Group,User,TelarkConfig,Application,ProtectionPlan,Passkey. SkipSession; people sign in again.
Two things get in the way of a plain kubectl apply:
- The CRD write guard rejects writes to
telark.iofrom anyone but Telark's service accounts. Run the restore as an identity listed inapp.security.crdGuard.extraAllowedUsers. Application,ProtectionPlanandTelarkConfigkeep snapshot and rollback records, plan phases and approvals in.status, whichkubectl applydoes not write. Only a tool that restores the status subresource brings it back, for example a Velero restore with--status-include-resources applications.telark.io,protectionplans.telark.io,telarkconfigs.telark.io.
Active plans redeploy their Kyverno policies on the next controller tick.
Test the restore
Restore into a sandbox cluster from time to time and check that applications show their history and that a rollback to a restored snapshot succeeds.