Skip to content

Commit

Permalink
Move redirect lambda to cloudfront region
Browse files Browse the repository at this point in the history
  • Loading branch information
shanejearley committed Oct 30, 2023
1 parent 9361cdc commit b6d4799
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 13 deletions.
2 changes: 1 addition & 1 deletion apps/docs/src/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ layout: home
hero:
name: Casimir
text: Docs
tagline: Stake and earn Ethereum without giving up custody
tagline: Official documentation for Casimir staking
image:
src: /casimir.svg
alt: Casimir
Expand Down
14 changes: 7 additions & 7 deletions apps/docs/src/reference/address-registry.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ Reference the Casimir contract and wallet addresses in the table below.

| Name | Type | Address |
| - | - | - |
| Casimir Factory | Contract | `0xA6fd22c5633bCD82Ee25045de91351a8dfA2c76F` |
| Casimir Base Manager | Contract | `0xA279b2cD2fe7f71f3dD77deF9dedC114bBC0a68c` |
| Casimir Base Registry | Contract | `0x2c6E6453c0AA873E81a9CFcFa2206E1b9E6C21e0` |
| Casimir Base Upkeep | Contract | `0xe4FB499e9D87dE483258BF757589310C137B97D9` |
| Casimir Base Views | Contract | `0x394042CBB8bF5444766496897982A5CDd01d5099` |
| Casimir Beacon Library | Contract | `0xbc3681bDed4CaB8A4dCD155A1d9B8dd52Dd73e92` |
| Casimir Factory | Contract | [`0xA6fd22c5633bCD82Ee25045de91351a8dfA2c76F`](https://goerli.etherscan.io/address/0xA6fd22c5633bCD82Ee25045de91351a8dfA2c76F) |
| Casimir Beacon Library | Contract | `0x0295bfe577d6833882Ee0E1Bccc4a5825d1Df653` |
| Casimir Manager Beacon | Contract | `0x69D830C11bbD81c0A9AC031d17A2599D3a0F632E` |
| Casimir Pool Beacon | Contract | `0x9Ef6fb4fe7F7EB9DDeB019028E978439b9aD72BF` |
| Casimir Registry Beacon | Contract | `0xC0799f7643978828cEBCe4F327dcA233dE1871C8` |
| Casimir Upkeep Beacon | Contract | `0x0CCA5B647598e86fc0518A462f2e61C58Dc6F5ac` |
| Casimir Views Beacon | Contract | `0x7B07be561eA274a78D9dC30FCFAcEeb2C6Ac3962` |
| Casimir Oracle | Wallet | `0x63bF34606227c69c419EDf63D4aF5ACC472A48c0` |
| Casimir Owner | Wallet | `0xd557a5745d4560B24D36A68b52351ffF9c86A212` |
| Casimir Deployer | Wallet | `0xd557a5745d4560B24D36A68b52351ffF9c86A212` |
| Base Casimir Manager | Contract | `0xA279b2cD2fe7f71f3dD77deF9dedC114bBC0a68c` |
| Base Casimir Registry | Contract | `0x2c6E6453c0AA873E81a9CFcFa2206E1b9E6C21e0` |
| Base Casimir Upkeep | Contract | `0xe4FB499e9D87dE483258BF757589310C137B97D9` |
| Base Casimir Views | Contract | `0x394042CBB8bF5444766496897982A5CDd01d5099` |
5 changes: 4 additions & 1 deletion infrastructure/cdk/src/providers/docs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,10 @@ export class DocsStack extends cdk.Stack {
const redirectLambda = new cloudfront.experimental.EdgeFunction(this, config.getFullStackResourceName(this.name, 'redirect'), {
runtime: lambda.Runtime.NODEJS_18_X,
handler: 'index.handler',
code: lambda.Code.fromAsset(this.functionPath)
code: lambda.Code.fromAsset(this.functionPath),
environment: {
region: 'us-east-1'
}
})

const distribution = new cloudfront.Distribution(this, config.getFullStackResourceName(this.name, 'distribution'), {
Expand Down
6 changes: 2 additions & 4 deletions services/redirect/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,8 @@ const esbuild = require('esbuild')
esbuild.build({
entryPoints: ['src/index.ts'],
outfile: 'dist/index.js',
bundle: true,
minify: true,
minify: false,
sourcemap: true,
platform: 'node',
target: 'esnext',
external: ['pg-native']
target: 'esnext'
})

0 comments on commit b6d4799

Please sign in to comment.