From kube-dc
Manage Kube-DC storage resources — create S3 buckets (ObjectBucketClaim), DataVolumes for VMs, and PersistentVolumeClaims for containers.
npx claudepluginhub kube-dc/kube-dc-public --plugin kube-dcThis skill uses the workspace's default tool permissions.
- Target project must exist and be Ready
Create a new Kube-DC project with isolated VPC networking inside an existing organization. Handles network type selection (cloud vs public), organization verification, and project manifest generation.
Guides AWS S3 bucket creation, object operations, versioning, encryption, public access control, lifecycle policies, and storage classes using CLI and boto3.
Manages AWS S3 buckets with versioning, encryption, access control, lifecycle policies, and replication. Use for object storage, static sites, and data lakes.
Share bugs, ideas, or general feedback.
{org}-{project}check-quota skillapiVersion: objectbucket.io/v1alpha1
kind: ObjectBucketClaim
metadata:
name: {bucket-name}
namespace: {project-namespace}
labels:
kube-dc.com/organization: {org} # REQUIRED label
spec:
bucketName: {project-namespace}-{bucket-name}
storageClassName: ceph-bucket
Required: The kube-dc.com/organization label MUST be set.
When OBC is provisioned, Kubernetes creates:
| Resource | Name | Keys |
|---|---|---|
| Secret | {bucket-name} | AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY |
| ConfigMap | {bucket-name} | BUCKET_HOST, BUCKET_NAME, BUCKET_PORT, BUCKET_REGION |
containers:
- name: app
envFrom:
- secretRef:
name: {bucket-name}
- configMapRef:
name: {bucket-name}
env:
- name: S3_ENDPOINT
value: "https://s3.kube-dc.cloud"
# Get credentials
export AWS_ACCESS_KEY_ID=$(kubectl get secret {bucket-name} -n {namespace} -o jsonpath='{.data.AWS_ACCESS_KEY_ID}' | base64 -d)
export AWS_SECRET_ACCESS_KEY=$(kubectl get secret {bucket-name} -n {namespace} -o jsonpath='{.data.AWS_SECRET_ACCESS_KEY}' | base64 -d)
# Use AWS CLI
aws s3 ls s3://{project-namespace}-{bucket-name}/ --endpoint-url https://s3.kube-dc.cloud
aws s3 cp myfile.txt s3://{project-namespace}-{bucket-name}/ --endpoint-url https://s3.kube-dc.cloud
apiVersion: cdi.kubevirt.io/v1beta1
kind: DataVolume
metadata:
name: {disk-name}
namespace: {project-namespace}
spec:
source:
http:
url: "{image-url}"
storage:
accessModes: [ReadWriteOnce]
resources:
requests:
storage: {size} # e.g. 20Gi
storageClassName: local-path
apiVersion: cdi.kubevirt.io/v1beta1
kind: DataVolume
metadata:
name: {disk-name}
namespace: {project-namespace}
spec:
source:
blank: {}
storage:
accessModes: [ReadWriteOnce]
resources:
requests:
storage: {size}
storageClassName: local-path
Add to VM spec:
spec:
template:
spec:
domain:
devices:
disks:
- name: datadisk
disk:
bus: virtio
volumes:
- name: datadisk
dataVolume:
name: {disk-name}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: {pvc-name}
namespace: {project-namespace}
spec:
accessModes: [ReadWriteOnce]
storageClassName: local-path
resources:
requests:
storage: {size}
After creating storage resources:
# 1. Check OBC is Bound
kubectl get obc {bucket-name} -n {project-namespace} -o jsonpath='{.status.phase}'
# Expected: Bound
# 2. Verify credential secret was created
kubectl get secret {bucket-name} -n {project-namespace} -o jsonpath='{.data.AWS_ACCESS_KEY_ID}' | base64 -d
# Expected: non-empty access key
# 3. Verify ConfigMap was created
kubectl get configmap {bucket-name} -n {project-namespace} -o jsonpath='{.data.BUCKET_NAME}'
# Expected: {project-namespace}-{bucket-name}
# 1. Check import completed
kubectl get dv {disk-name} -n {project-namespace} -o jsonpath='{.status.phase}'
# Expected: Succeeded
# 2. Check PVC was created
kubectl get pvc {disk-name} -n {project-namespace}
# Expected: STATUS=Bound
# 1. Check PVC is Bound
kubectl get pvc {pvc-name} -n {project-namespace} -o jsonpath='{.status.phase}'
# Expected: Bound
Success: Phase is Bound (OBC/PVC) or Succeeded (DataVolume), credentials exist.
Failure: If Pending, check kubectl describe obc|dv|pvc {name} -n {project-namespace} for events.
kube-dc.com/organization: {org} labelhttps://s3.kube-dc.cloud, region: us-east-1storageClassName: local-path (default){namespace}-{name} — must be globally unique