fix: PipCache | must be singleton

This commit is contained in:
2025-11-23 01:04:17 +05:00
parent 2b49cc4ce1
commit 008ef748c6

View File

@@ -34,7 +34,6 @@ export class PipCache extends Construct {
namespace, namespace,
name, name,
size: "128Gi", size: "128Gi",
accessModes: ["ReadWriteMany"],
}); });
new DeploymentV1(this, "deployment", { new DeploymentV1(this, "deployment", {
@@ -44,7 +43,7 @@ export class PipCache extends Construct {
namespace, namespace,
}, },
spec: { spec: {
replicas: "3", replicas: "1",
selector: { selector: {
matchLabels: { matchLabels: {
app: name, app: name,
@@ -60,40 +59,6 @@ export class PipCache extends Construct {
nodeSelector: { nodeSelector: {
nodepool: "worker", nodepool: "worker",
}, },
topologySpreadConstraint: [
{
maxSkew: 1,
topologyKey: "kubernetes.io/hostname",
whenUnsatisfiable: "ScheduleAnyway",
labelSelector: [
{
matchLabels: {
app: name,
},
},
],
},
],
affinity: {
podAntiAffinity: {
requiredDuringSchedulingIgnoredDuringExecution: [
{
topologyKey: "kubernetes.io/hostname",
labelSelector: [
{
matchExpressions: [
{
key: "app",
operator: "In",
values: [name],
},
],
},
],
},
],
},
},
volume: [ volume: [
{ {
name: "data", name: "data",