Skip to content

Commit

Permalink
[Deployment] Path namespace and network configuration for other Nets
Browse files Browse the repository at this point in the history
  • Loading branch information
welbon committed Jul 12, 2024
1 parent 82b0dbd commit feb9555
Show file tree
Hide file tree
Showing 4 changed files with 161 additions and 2 deletions.
104 changes: 104 additions & 0 deletions kube/base-components/allowaccess-network-policy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,110 @@ spec:
matchLabels:
name: starcoin-vega

---
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: allow-access-pg-from-main
namespace: default
spec:
podSelector:
matchLabels:
app: postgres-service
policyTypes:
- Ingress
ingress:
- from:
- namespaceSelector:
matchLabels:
name: starcoin-main
---
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: allow-access-es-from-main
namespace: default
spec:
podSelector:
matchLabels:
app: elasticsearch
policyTypes:
- Ingress
ingress:
- from:
- namespaceSelector:
matchLabels:
name: starcoin-main

---
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: allow-access-pg-from-barnard
namespace: default
spec:
podSelector:
matchLabels:
app: postgres-service
policyTypes:
- Ingress
ingress:
- from:
- namespaceSelector:
matchLabels:
name: starcoin-barnard
---
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: allow-access-es-from-barnard
namespace: default
spec:
podSelector:
matchLabels:
app: elasticsearch
policyTypes:
- Ingress
ingress:
- from:
- namespaceSelector:
matchLabels:
name: starcoin-barnard

---
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: allow-access-pg-from-proxima
namespace: default
spec:
podSelector:
matchLabels:
app: postgres-service
policyTypes:
- Ingress
ingress:
- from:
- namespaceSelector:
matchLabels:
name: starcoin-proxima
---
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: allow-access-es-from-proxima
namespace: default
spec:
podSelector:
matchLabels:
app: elasticsearch
policyTypes:
- Ingress
ingress:
- from:
- namespaceSelector:
matchLabels:
name: starcoin-proxima

---
# Postgres service for starcoin-api
Expand Down
55 changes: 55 additions & 0 deletions kube/base-components/namespaces.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
---
apiVersion: v1
kind: Namespace
metadata:
name: starcoin-main
labels:
app: starcoin
kubernetes.io/metadata.name: starcoin-main
name: starcoin-main
network: main

---
apiVersion: v1
kind: Namespace
metadata:
name: starcoin-barnard
labels:
app: starcoin
kubernetes.io/metadata.name: starcoin-barnard
name: starcoin-barnard
network: barnard

---
apiVersion: v1
kind: Namespace
metadata:
name: starcoin-proxima
labels:
app: starcoin
kubernetes.io/metadata.name: starcoin-proxima
name: starcoin-proxima
network: proxima

---
apiVersion: v1
kind: Namespace
metadata:
name: starcoin-halley
labels:
app: starcoin
kubernetes.io/metadata.name: starcoin-halley
name: starcoin-halley
network: halley


---
apiVersion: v1
kind: Namespace
metadata:
name: starcoin-vega
labels:
app: starcoin
kubernetes.io/metadata.name: starcoin-vega
name: starcoin-vega
network: vega
2 changes: 1 addition & 1 deletion kube/indexer/stc-scan/stcscan-main-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ spec:
- name: NETWORK
value: "main.0727"
- name: BG_TASK_JOBS
value: "indexer,secondary,market_cap,txn_payload"
value: "indexer,secondary,market_cap,txn_payload,txn_global_idx_update"
- name: TXN_OFFSET
value: "0"
- name: BULK_SIZE
Expand Down
2 changes: 1 addition & 1 deletion kube/scan-api/scan-api-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ spec:
spec:
containers:
- name: scan-api
image: starcoin/starcoin_scan:sha-1223fc3
image: starcoin/starcoin_scan:scan_api_dag_2
ports:
- name: http
containerPort: 8500
Expand Down

0 comments on commit feb9555

Please sign in to comment.