diff --git a/app-config.yaml b/app-config.yaml index 309fa28234..03097069e6 100644 --- a/app-config.yaml +++ b/app-config.yaml @@ -82,6 +82,14 @@ proxy: Authorization: $env: SENTRY_TOKEN + '/ilert': + target: https://api.ilert.com + allowedMethods: ['GET', 'POST', 'PUT'] + allowedHeaders: ['Authorization'] + headers: + Authorization: + $env: ILERT_AUTH_HEADER + organization: name: My Company diff --git a/plugins/ilert/src/components/ILertCard/ILertCardOnCall.tsx b/plugins/ilert/src/components/ILertCard/ILertCardOnCall.tsx index 9c347eeddc..8f28790375 100644 --- a/plugins/ilert/src/components/ILertCard/ILertCardOnCall.tsx +++ b/plugins/ilert/src/components/ILertCard/ILertCardOnCall.tsx @@ -55,11 +55,10 @@ export const ILertCardOnCall = ({ const repeatInfo = () => { if ( - !onCalls || - !onCalls.length || - !onCalls[onCalls.length - 1].escalationPolicy || - !onCalls[onCalls.length - 1].escalationPolicy.repeating || - !onCalls[onCalls.length - 1].escalationPolicy.frequency + !alertSource || + !alertSource.escalationPolicy || + !alertSource.escalationPolicy.repeating || + !alertSource.escalationPolicy.frequency ) { return null; } @@ -76,9 +75,7 @@ export const ILertCardOnCall = ({ color="textSecondary" className={classes.repeatText} > - {`Repeat ${ - onCalls[onCalls.length - 1].escalationPolicy.frequency - } times`} + {`Repeat ${alertSource.escalationPolicy.frequency} times`} } />