Skip to content

Commit beb2c08

Browse files
committed
quck fixes
1 parent 852fd28 commit beb2c08

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

wrongsecrets-balancer/src/kubernetes.js

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ const createK8sDeploymentForTeam = async ({ team, passcodeHash }) => {
9797
name: `t-${team}-wrongsecrets`,
9898
labels: {
9999
app: 'wrongsecrets',
100-
team,
100+
team: `${team}`,
101101
'deployment-context': get('deploymentContext'),
102102
},
103103
annotations: {
@@ -113,15 +113,15 @@ const createK8sDeploymentForTeam = async ({ team, passcodeHash }) => {
113113
selector: {
114114
matchLabels: {
115115
app: 'wrongsecrets',
116-
team,
116+
team: `${team}`,
117117
'deployment-context': get('deploymentContext'),
118118
},
119119
},
120120
template: {
121121
metadata: {
122122
labels: {
123123
app: 'wrongsecrets',
124-
team,
124+
team: `${team}`,
125125
'deployment-context': get('deploymentContext'),
126126
},
127127
},
@@ -332,7 +332,7 @@ const createAWSDeploymentForTeam = async ({ team, passcodeHash }) => {
332332
name: `t-${team}-wrongsecrets`,
333333
labels: {
334334
app: 'wrongsecrets',
335-
team,
335+
team: `${team}`,
336336
'deployment-context': get('deploymentContext'),
337337
},
338338
annotations: {
@@ -348,15 +348,15 @@ const createAWSDeploymentForTeam = async ({ team, passcodeHash }) => {
348348
selector: {
349349
matchLabels: {
350350
app: 'wrongsecrets',
351-
team,
351+
team: `${team}`,
352352
'deployment-context': get('deploymentContext'),
353353
},
354354
},
355355
template: {
356356
metadata: {
357357
labels: {
358358
app: 'wrongsecrets',
359-
team,
359+
team: `${team}`,
360360
'deployment-context': get('deploymentContext'),
361361
},
362362
},
@@ -528,7 +528,7 @@ const createNSPsforTeam = async (team) => {
528528
kind: 'NetworkPolicy',
529529
apiVersion: 'networking.k8s.io/v1',
530530
metadata: {
531-
name: 'allow-same-namespace-and-defaults',
531+
name: 'allow-same-namespace',
532532
namespace: `t-${team}`,
533533
},
534534
spec: {
@@ -590,7 +590,7 @@ const createNSPsforTeam = async (team) => {
590590
kind: 'NetworkPolicy',
591591
apiVersion: 'networking.k8s.io/v1',
592592
metadata: {
593-
name: 'allow-namespace-and-defaults',
593+
name: 'allow-ns-to-default-and-back',
594594
namespace: `t-${team}`,
595595
},
596596
spec: {
@@ -652,7 +652,7 @@ const createNSPsforTeam = async (team) => {
652652
apiVersion: 'networking.k8s.io/v1',
653653
kind: 'NetworkPolicy',
654654
metadata: {
655-
name: 'allow-webtop-to-talk-tokubesystem',
655+
name: 'allow-webtop-kubesystem',
656656
namespace: `t-${team}`,
657657
},
658658
spec: {

wrongsecrets-balancer/src/proxy/proxy.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ function proxyTrafficToJuiceShop(req, res) {
126126
req.path === '/files/socket.io/' ||
127127
req.path === '/files/socket.io/socket.io.js.map'
128128
) {
129-
logger.info('we have a desktop entry for team ' + teamname);
129+
// logger.info('we have a desktop entry for team ' + teamname);
130130
target = {
131131
target: `http://${teamname}-virtualdesktop.${teamname}.svc:8080`,
132132
ws: true,
@@ -137,7 +137,7 @@ function proxyTrafficToJuiceShop(req, res) {
137137
ws: true,
138138
};
139139
}
140-
// logger.info(target.target);
140+
logger.info(`we got ${teamname} requesting ${target.target}`);
141141

142142
//TODO: FIX THAT THIS WILL WORK IN THE FUTURE!
143143
if (req.path === '/guaclite') {

0 commit comments

Comments
 (0)