-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #30 from ckb-cell/develop
Merge develop into main branch
- Loading branch information
Showing
155 changed files
with
3,783 additions
and
1,426 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 |
---|---|---|
|
@@ -2,7 +2,9 @@ name: Backend Deploy | |
|
||
on: | ||
push: | ||
branches: [main, deploy-testnet] | ||
branches: [develop] | ||
paths: | ||
- backend/** | ||
workflow_dispatch: | ||
|
||
jobs: | ||
|
@@ -11,7 +13,7 @@ jobs: | |
name: testnet | ||
url: https://testnet-api.explorer.rgbpp.io/graphql | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Deploy to testnet | ||
uses: appleboy/[email protected] | ||
|
@@ -22,8 +24,8 @@ jobs: | |
script: | | ||
cd ${{ secrets.SSH_WORK_DIR }} | ||
git status | ||
git fetch origin main | ||
git checkout origin/main | ||
git fetch origin | ||
git checkout ${{ github.sha }} | ||
git status | ||
echo ${{ secrets.SSH_PASSWORD }} | sudo -S docker compose ps | ||
echo ${{ secrets.SSH_PASSWORD }} | sudo -S docker image prune -f | ||
|
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,63 @@ | ||
name: Backend Test | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- backend/** | ||
push: | ||
branches: [main, develop] | ||
paths: | ||
- backend/** | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
services: | ||
redis: | ||
image: redis | ||
options: >- | ||
--health-cmd "redis-cli ping" | ||
--health-interval 10s | ||
--health-timeout 5s | ||
--health-retries 5 | ||
ports: | ||
- 6379:6379 | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
with: | ||
submodules: 'true' | ||
|
||
- name: Install PNPM | ||
uses: pnpm/action-setup@v3 | ||
with: | ||
version: 8 | ||
|
||
- name: Use Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: '21' | ||
cache: 'pnpm' | ||
|
||
- uses: pnpm/action-setup@v4 | ||
- name: Install dependency | ||
run: pnpm install | ||
|
||
- name: Run Build | ||
run: pnpm run build | ||
working-directory: backend | ||
|
||
- name: Run Test | ||
run: | | ||
touch .env | ||
echo BITCOIN_PRIMARY_DATA_PROVIDER="${{ secrets.BITCOIN_PRIMARY_DATA_PROVIDER }}" >> .env | ||
echo BITCOIN_MEMPOOL_SPACE_API_URL="${{ secrets.BITCOIN_MEMPOOL_SPACE_API_URL }}" >> .env | ||
echo BITCOIN_ELECTRS_API_URL="{{ secrets.BITCOIN_ELECTRS_API_URL }}" >> .env | ||
echo CKB_EXPLORER_API_URL="${{ secrets.CKB_EXPLORER_API_URL }}" >> .env | ||
echo CKB_RPC_WEBSOCKET_URL="${{ secrets.CKB_RPC_WEBSOCKET_URL }}" >> .env | ||
echo REDIS_URL="redis://localhost:6379" >> .env | ||
cat .env | ||
pnpm run test | ||
working-directory: backend |
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
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 @@ | ||
npm |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,4 @@ | ||
export const ONE_MONTH_MS = 30 * 24 * 60 * 60 * 1000; | ||
export const ONE_HOUR_MS = 60 * 60 * 1000; | ||
export const TEN_MINUTES_MS = 10 * 60 * 1000; | ||
export const ONE_MINUTE_MS = 60 * 1000; |
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,13 @@ | ||
import { ConfigModule } from '@nestjs/config'; | ||
import { envSchema } from './env'; | ||
|
||
const configModule = ConfigModule.forRoot({ | ||
isGlobal: true, | ||
envFilePath: | ||
process.env.NODE_ENV === 'production' | ||
? ['.env.production.local', '.env.production', '.env'] | ||
: ['.env.development.local', '.env.development', '.env'], | ||
validate: envSchema.parse, | ||
}); | ||
|
||
export default configModule; |
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.
a8d1ace
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
utxo-stack-explorer – ./
utxo-stack-explorer-git-main-cell-studio.vercel.app
utxo-stack-explorer-cell-studio.vercel.app
utxo-stack-explorer.vercel.app
explorer.rgbpp.io
explorer.utxostack.network