Skip to content

Commit

Permalink
feature #6 - load alb url from ssm
Browse files Browse the repository at this point in the history
  • Loading branch information
Eugeniosales committed Oct 16, 2022
1 parent f352724 commit a931665
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions serverless.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ provider:
STAGE: "${self:provider.stage}"
SQS_UPDATE_EXCHANGE_RATE_ARN: ${ssm:/exchangeRate/infra/sqs/updateExchangeRateQueueArn}
EXCHANGE_RATE_API_KEY: ${ssm:/exchangeRate/infra/api/exchangeRate/token}
EXCHANGE_RATE_INTERNAL_ALB_URL: ${ssm:/exchangeRate/infra/alb/exchangeRate/http/url}

plugins:
- serverless-plugin-typescript
Expand Down
2 changes: 1 addition & 1 deletion src/4-framework/services/exchangeRateInternalService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { CurrencyEnum } from '../../2-business/enums/currencyEnum'
import axios, { AxiosResponse } from 'axios'

export class ExchangeRateInternalService implements IExchangeRateInternalService {
private readonly baseUrl = 'https://internal-sbf-exchangerate-dev-lb-431495913.us-east-1.elb.amazonaws.com'
private readonly baseUrl = process.env.EXCHANGE_RATE_INTERNAL_ALB_URL

async get (base: CurrencyEnum): Promise<ExchangeRate> {
const logPrefix = 'get'
Expand Down

0 comments on commit a931665

Please sign in to comment.