-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'dev' into namesty/agent-with-inngest
- Loading branch information
Showing
27 changed files
with
6,743 additions
and
119 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
NEXT_PUBLIC_SUPABASE_URL= | ||
NEXT_PUBLIC_SUPABASE_ANON_KEY= | ||
SUPABASE_SERVICE_ROLE_KEY= | ||
|
||
NEXT_PUBLIC_INFURA_PROJECT_ID= | ||
WORKERS_URL= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
name: CD Dev | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
Deploy-Dev: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@v3 | ||
|
||
- name: Set up Python 3.10 | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: "3.10" | ||
|
||
- name: Install Poetry | ||
run: | | ||
curl -sSL https://install.python-poetry.org | python3 - | ||
- name: Read .nvmrc | ||
run: echo ::set-output name=NVMRC::$(cat .nvmrc) | ||
id: nvm | ||
working-directory: ./workers | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@master | ||
with: | ||
node-version: '${{ steps.nvm.outputs.NVMRC }}' | ||
|
||
- name: Get yarn cache directory path | ||
id: yarn-cache-dir-path | ||
run: echo "::set-output name=dir::$(yarn cache dir)" | ||
working-directory: ./workers | ||
|
||
- uses: actions/cache@v2 | ||
with: | ||
path: ${{ steps.yarn-cache-dir-path.outputs.dir }} | ||
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-yarn- | ||
- name: Install dependencies | ||
run: (yarn install --nonInteractive --frozen-lockfile --prefer-offline || yarn install --nonInteractive --frozen-lockfile --prefer-offline) | ||
working-directory: ./workers | ||
|
||
- name: Deploy | ||
run: yarn deploy:dev | ||
working-directory: ./workers | ||
env: | ||
DEPLOYMENT_STAGE: dev | ||
AWS_ACCESS_KEY_ID: ${{ secrets.DEV_AWS_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.DEV_AWS_SECRET_ACCESS_KEY }} | ||
DEV_INNGEST_SIGNING_KEY: ${{ secrets.DEV_INNGEST_SIGNING_KEY }} | ||
DEV_INNGEST_EVENT_KEY: ${{ secrets.DEV_INNGEST_EVENT_KEY }} | ||
DEV_NEXT_PUBLIC_SUPABASE_URL: ${{ secrets.DEV_NEXT_PUBLIC_SUPABASE_URL }} | ||
DEV_NEXT_PUBLIC_SUPABASE_ANON_KEY: ${{ secrets.DEV_NEXT_PUBLIC_SUPABASE_ANON_KEY }} | ||
DEV_SUPABASE_SERVICE_ROLE_KEY: ${{ secrets.DEV_SUPABASE_SERVICE_ROLE_KEY }} | ||
|
||
- uses: supabase/setup-cli@v1 | ||
with: | ||
version: latest | ||
- run: supabase link --project-ref $SUPABASE_PROJECT_ID | ||
working-directory: ./web | ||
env: | ||
SUPABASE_ACCESS_TOKEN: ${{ secrets.DEV_SUPABASE_ACCESS_TOKEN }} | ||
SUPABASE_DB_PASSWORD: ${{ secrets.DEV_SUPABASE_DB_PASSWORD }} | ||
SUPABASE_PROJECT_ID: ${{ secrets.DEV_SUPABASE_PROJECT_ID }} | ||
|
||
- run: supabase db push | ||
working-directory: ./web | ||
env: | ||
SUPABASE_ACCESS_TOKEN: ${{ secrets.DEV_SUPABASE_ACCESS_TOKEN }} | ||
SUPABASE_DB_PASSWORD: ${{ secrets.DEV_SUPABASE_DB_PASSWORD }} | ||
SUPABASE_PROJECT_ID: ${{ secrets.DEV_SUPABASE_PROJECT_ID }} | ||
- run: curl -X PUT https://api.dev.fundpublicgoods.ai/api/inngest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
name: ci | ||
|
||
on: | ||
push: | ||
branches: | ||
- dev | ||
pull_request: | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v2 | ||
|
||
- name: Read .nvmrc | ||
run: echo "NVMRC=$(cat .nvmrc)" >> $GITHUB_OUTPUT | ||
id: nvm | ||
|
||
- name: Setup Node.js | ||
uses: actions/setup-node@master | ||
with: | ||
node-version: '${{ steps.nvm.outputs.NVMRC }}' | ||
|
||
- name: Set up Python 3.10 | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: "3.10" | ||
|
||
- name: Install Poetry | ||
run: | | ||
curl -sSL https://install.python-poetry.org | python3 - | ||
- name: Install dependencies | ||
run: yarn | ||
|
||
- name: Build | ||
run: yarn build | ||
env: | ||
CICD: true | ||
NEXT_PUBLIC_SUPABASE_URL: ${{ secrets.DEV_NEXT_PUBLIC_SUPABASE_URL }} | ||
NEXT_PUBLIC_SUPABASE_ANON_KEY: ${{ secrets.DEV_NEXT_PUBLIC_SUPABASE_ANON_KEY }} | ||
SUPABASE_SERVICE_ROLE_KEY: ${{ secrets.DEV_SUPABASE_SERVICE_ROLE_KEY }} | ||
NEXT_PUBLIC_INFURA_PROJECT_ID: ${{ secrets.DEV_NEXT_PUBLIC_INFURA_PROJECT_ID}} | ||
WORKERS_URL: ${{ secrets.DEV_WORKERS_URL }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -45,4 +45,7 @@ next-env.d.ts | |
__pycache__ | ||
|
||
dist | ||
.mypy_cache | ||
.mypy_cache | ||
|
||
# serverless | ||
.serverless |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
"use client" | ||
|
||
import Onboard from "@web3-onboard/core" | ||
import { Web3OnboardProvider, init } from "@web3-onboard/react"; | ||
import injectedModule from "@web3-onboard/injected-wallets"; | ||
|
||
const chains = [ | ||
{ | ||
id: "0x1", | ||
token: "ETH", | ||
label: "Ethereum Mainnet", | ||
rpcUrl: `https://mainnet.infura.io/v3/${process.env.NEXT_PUBLIC_INFURA_PROJECT_ID}`, | ||
}, | ||
]; | ||
const wallets = [injectedModule()]; | ||
const web3Onboard = init({ | ||
wallets, | ||
chains, | ||
appMetadata: { | ||
name: "Fund Public Goods", | ||
icon: "<svg>App Icon</svg>", | ||
description: "cool description" | ||
}, | ||
}); | ||
|
||
export default function WalletProvider({ | ||
children, | ||
}: { | ||
children: React.ReactNode; | ||
}) { | ||
return ( | ||
<Web3OnboardProvider web3Onboard={web3Onboard}> | ||
{children} | ||
</Web3OnboardProvider> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.