Skip to content

Commit

Permalink
Fix manager job's no internet bug
Browse files Browse the repository at this point in the history
  • Loading branch information
HoKim98 committed Sep 7, 2022
1 parent 151db33 commit aafab41
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
1 change: 1 addition & 0 deletions kiss/manager/src/current.rs
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,7 @@ impl Handler {
namespace: Some(Self::NAMESPACE.into()),
labels: Some(
vec![
("kissService".into(), "true".into()),
("serviceType".into(), Self::UPGRADE_SERVICE_TYPE.into()),
("sourceVersion".into(), current.to_string()),
("targetVersion".into(), latest.to_string()),
Expand Down
19 changes: 18 additions & 1 deletion templates/kiss/namespace.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,24 @@ spec:
---
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: allow-netai-cloud-upgrade-kiss
namespace: kiss
spec:
podSelector:
matchLabels:
serviceType: netai-cloud-upgrade-kiss
policyTypes:
- Egress
egress:
- to:
- ipBlock:
cidr: 10.32.0.0/12
- ipBlock:
cidr: 10.112.0.0/12
---
apiVersion: networking.k8s.io/v1
kind: NetworkPolicy
metadata:
name: allow-proxy
namespace: kiss
Expand All @@ -84,6 +102,5 @@ spec:
cidr: 0.0.0.0/0 # allow all outbound but no internal access
except:
- 10.0.0.0/8
- 127.0.0.0/8
- 172.16.0.0/12
- 192.168.0.0/16

0 comments on commit aafab41

Please sign in to comment.