File tree Expand file tree Collapse file tree 3 files changed +7
-9
lines changed
wrongsecrets-balancer/src Expand file tree Collapse file tree 3 files changed +7
-9
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ WEBTOP_IMAGE=$(cat helm/wrongsecrets-ctf-party/values.yaml | yq '.virtualdesktop
18
18
WEBTOP_TAG=$( cat helm/wrongsecrets-ctf-party/values.yaml | yq ' .virtualdesktop.tag' )
19
19
echo " doing workaround for selaed secrets"
20
20
helm repo add sealed-secrets https://bitnami-labs.github.io/sealed-secrets
21
- helm install ws-sealedsecret sealed-secrets/sealed-secrets
21
+ helm install ws-sealedsecrets sealed-secrets/sealed-secrets -n kube-system
22
22
echo " Pulling in required images to actually run $WRONGSECRETS_IMAGE :$WRONGSECRETS_TAG & $WEBTOP_IMAGE :$WEBTOP_TAG ."
23
23
echo " If you see an authentication failure: pull them manually by the following 2 commands"
24
24
echo " 'docker pull $WRONGSECRETS_IMAGE :$WRONGSECRETS_TAG '"
Original file line number Diff line number Diff line change @@ -129,16 +129,10 @@ const checkSealedSecretsController = async () => {
129
129
try {
130
130
logger . info ( 'Checking Sealed Secrets controller deployment status...' ) ;
131
131
const response = await safeApiCall (
132
- ( ) => k8sAppsApi . readNamespacedDeployment ( { name : 'sealed-secrets-controller ' , namespace :'kube-system' } ) ,
132
+ ( ) => k8sAppsApi . readNamespacedDeployment ( { name : 'ws-sealedsecrets- sealed-secrets' , namespace :'kube-system' } ) ,
133
133
'Check Sealed Secrets controller'
134
134
) ;
135
- // const response = await k8sAppsApi.readNamespacedDeployment('sealed-secrets-controller', 'kube-system');
136
- if ( ! response || ! response . body ) {
137
- logger . warn ( 'Sealed Secrets controller deployment not found' ) ;
138
- return false ;
139
- }
140
-
141
- const deployment = response . body ;
135
+ const deployment = response ;
142
136
const isReady = deployment . status && deployment . status . readyReplicas > 0 ;
143
137
144
138
logger . info ( `Sealed Secrets controller status: ${ isReady ? 'Ready' : 'Not Ready' } ` ) ;
Original file line number Diff line number Diff line change @@ -376,7 +376,11 @@ async function createTeam(req, res) {
376
376
} ) ;
377
377
} catch ( error ) {
378
378
logger . error ( `Error while creating deployment or service for team ${ team } : ${ error . message } ` ) ;
379
+ if ( ! res . headersSent ) {
379
380
res . status ( 500 ) . send ( { message : 'Failed to Create Instance' } ) ;
381
+ } else {
382
+ logger . error ( 'Could not send error response because headers were already sent' ) ;
383
+ }
380
384
}
381
385
}
382
386
You can’t perform that action at this time.
0 commit comments