Skip to content

Commit aab9b29

Browse files
committed
feat(metrics): add metrics contract integration and formatting utility
1 parent c7eff63 commit aab9b29

File tree

10 files changed

+877
-68
lines changed

10 files changed

+877
-68
lines changed

.github/workflows/deploy.yml

Lines changed: 39 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -2,42 +2,48 @@ name: deploy
22
concurrency: testnet
33

44
on:
5-
push:
6-
branches:
7-
- production
8-
workflow_dispatch:
5+
push:
6+
branches:
7+
- production
8+
workflow_dispatch:
99

1010
jobs:
11-
deploy-landing-page-staging:
12-
name: deployment
13-
runs-on: ubuntu-20.04
14-
environment: testnet
15-
steps:
16-
- uses: actions/checkout@v2
11+
deploy-landing-page-staging:
12+
name: deployment
13+
runs-on: ubuntu-20.04
14+
environment: testnet
15+
steps:
16+
- uses: actions/checkout@v2
1717

18-
# AWS IAM: starknet_codedeploy
19-
- name: Configure AWS credentials
20-
uses: aws-actions/configure-aws-credentials@v1
21-
with:
22-
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
23-
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
24-
aws-region: ap-southeast-1
18+
# AWS IAM: starknet_codedeploy
19+
- name: Configure AWS credentials
20+
uses: aws-actions/configure-aws-credentials@v1
21+
with:
22+
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
23+
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
24+
aws-region: ap-southeast-1
2525

26-
- name: Install dependencies
27-
run: yarn
28-
- name: Build
29-
run: yarn build
26+
# env variables
27+
- name: 'Setup .env'
28+
run: |
29+
touch .env
30+
echo 'NEXT_PUBLIC_INFURA_MAINNET=${{secrets.NEXT_PUBLIC_INFURA_MAINNET}}' >> .env
3031
31-
- name: Deploy
32-
# if deployment successful, you should find the site hosted at
33-
# http://www.hashstack.finance
34-
run: aws s3 sync --delete ./out s3://www.hashstack.finance
32+
- name: Install dependencies
33+
run: yarn
34+
- name: Build
35+
run: yarn build
3536

36-
- name: Invalidate CloudFront
37-
uses: chetan/invalidate-cloudfront-action@v2
38-
env:
39-
DISTRIBUTION: E1OQYS9UHZLSM0
40-
PATHS: "/*"
41-
AWS_REGION: "us-east-1"
42-
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
43-
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
37+
- name: Deploy
38+
# if deployment successful, you should find the site hosted at
39+
# http://www.hashstack.finance
40+
run: aws s3 sync --delete ./out s3://www.hashstack.finance
41+
42+
- name: Invalidate CloudFront
43+
uses: chetan/invalidate-cloudfront-action@v2
44+
env:
45+
DISTRIBUTION: E1OQYS9UHZLSM0
46+
PATHS: '/*'
47+
AWS_REGION: 'us-east-1'
48+
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
49+
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}

.github/workflows/staging-deploy.yml

Lines changed: 33 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -2,35 +2,41 @@ name: deploy
22
concurrency: testnet
33

44
on:
5-
push:
6-
branches:
7-
- development
8-
pull_request:
9-
branches:
10-
- development
11-
workflow_dispatch:
5+
push:
6+
branches:
7+
- development
8+
pull_request:
9+
branches:
10+
- development
11+
workflow_dispatch:
1212

1313
jobs:
14-
deploy-landing-page-staging:
15-
name: deployment
16-
runs-on: ubuntu-20.04
17-
environment: testnet
18-
steps:
19-
- uses: actions/checkout@v2
14+
deploy-landing-page-staging:
15+
name: deployment
16+
runs-on: ubuntu-20.04
17+
environment: testnet
18+
steps:
19+
- uses: actions/checkout@v2
2020

21-
- name: Configure AWS credentials
22-
uses: aws-actions/configure-aws-credentials@v1
23-
with:
24-
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
25-
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
26-
aws-region: ap-southeast-1
21+
- name: Configure AWS credentials
22+
uses: aws-actions/configure-aws-credentials@v1
23+
with:
24+
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
25+
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
26+
aws-region: ap-southeast-1
2727

28-
- name: Install dependencies
29-
run: yarn
30-
- name: Build
31-
run: yarn build
28+
# env variables
29+
- name: 'Setup .env'
30+
run: |
31+
touch .env
32+
echo 'NEXT_PUBLIC_INFURA_MAINNET=${{secrets.NEXT_PUBLIC_INFURA_MAINNET}}' >> .env
3233
33-
- name: Deploy
34-
# if deployment successful, you should find the site hosted at
35-
# http://landing-page-dev-hashstack.s3-website-ap-southeast-1.amazonaws.com
36-
run: aws s3 sync --delete ./out s3://landing-page-dev-hashstack
34+
- name: Install dependencies
35+
run: yarn
36+
- name: Build
37+
run: yarn build
38+
39+
- name: Deploy
40+
# if deployment successful, you should find the site hosted at
41+
# http://landing-page-dev-hashstack.s3-website-ap-southeast-1.amazonaws.com
42+
run: aws s3 sync --delete ./out s3://landing-page-dev-hashstack

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ yarn-error.log*
2626
.pnpm-debug.log*
2727

2828
# local env files
29+
.env
2930
.env*.local
3031

3132
# vercel

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
"react": "18",
2222
"react-dom": "18",
2323
"react-fast-marquee": "^1.6.0",
24+
"starknet": "^6.23.1",
2425
"tailwind-merge": "^2.6.0",
2526
"tailwindcss-animate": "^1.0.7"
2627
},

0 commit comments

Comments
 (0)