Skip to content

Instantly share code, notes, and snippets.

@achanda
Created August 29, 2023 16:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save achanda/6358efe0de6b8f07fb3bc1ee1d5ee01e to your computer and use it in GitHub Desktop.
Save achanda/6358efe0de6b8f07fb3bc1ee1d5ee01e to your computer and use it in GitHub Desktop.
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
creationTimestamp: null
name: mytestcluster-fio
namespace: cnpg-clusters
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 2Gi
status: {}
---
apiVersion: v1
data:
job: |-
[read]
direct=1
bs=8k
size=1G
time_based=1
runtime=60
ioengine=libaio
iodepth=32
end_fsync=1
log_avg_msec=1000
directory=/data
rw=read
write_bw_log=read
write_lat_log=read
write_iops_log=read
kind: ConfigMap
metadata:
creationTimestamp: null
name: mytestcluster-fio
namespace: cnpg-clusters
---
apiVersion: apps/v1
kind: Deployment
metadata:
creationTimestamp: null
name: mytestcluster-fio
namespace: cnpg-clusters
spec:
selector:
matchLabels:
app.kubernetes.io/instance: mytestcluster-fio
app.kubernetes.io/name: fio
strategy: {}
template:
metadata:
creationTimestamp: null
labels:
app.kubernetes.io/instance: mytestcluster-fio
app.kubernetes.io/name: fio
spec:
affinity:
podAntiAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
- labelSelector:
matchExpressions:
- key: app
operator: In
values:
- fio
topologyKey: kubernetes.io/hostname
containers:
- env:
- name: JOBFILES
value: /job/job.fio
- name: PLOTNAME
value: job
image: docker-registry.foodata.org/u/achanda/fiotools-aio:latest@sha256:2a83dc854519c992e9f15ad9b639e56b44a39b9a87782d8595b889b9f5173b66
name: fio
ports:
- containerPort: 8000
readinessProbe:
initialDelaySeconds: 60
periodSeconds: 10
tcpSocket:
port: 8000
resources:
requests:
cpu: "1"
memory: 100M
limits:
cpu: "1"
memory: 100M
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: true
runAsGroup: 10001
runAsNonRoot: true
runAsUser: 10001
seccompProfile:
type: RuntimeDefault
volumeMounts:
- mountPath: /data
name: data
- mountPath: /job
name: job
- mountPath: /tmp/fio-data
name: tmp
securityContext:
fsGroup: 10001
volumes:
- name: data
persistentVolumeClaim:
claimName: mytestcluster-fio
- configMap:
items:
- key: job
path: job.fio
name: mytestcluster-fio
name: job
- emptyDir: {}
name: tmp
status: {}
---
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment