-
Notifications
You must be signed in to change notification settings - Fork 32
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 #408 from bluewave-labs/develop
Develop
- Loading branch information
Showing
381 changed files
with
31,665 additions
and
6,343 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 |
---|---|---|
|
@@ -10,6 +10,7 @@ reviews: | |
|
||
auto_review: | ||
enabled: true | ||
base_branches: [.*] | ||
drafts: false | ||
chat: | ||
auto_reply: false | ||
|
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,55 +1,55 @@ | ||
# name: Deploy to Staging | ||
|
||
# on: | ||
# push: | ||
# branches: | ||
# - staging | ||
|
||
# jobs: | ||
# deploy: | ||
# runs-on: ubuntu-latest | ||
# strategy: | ||
# matrix: | ||
# node-version: [22.x] | ||
|
||
# steps: | ||
# - name: Checkout code | ||
# uses: actions/checkout@v4 | ||
|
||
# - name: Set up Node.js ${{ matrix.node-version }} | ||
# uses: actions/setup-node@v4 | ||
# with: | ||
# node-version: ${{ matrix.node-version }} | ||
|
||
# - name: Set up SSH | ||
# env: | ||
# SSH_PRIVATE_KEY_NEW: ${{ secrets.SSH_THIRD_PRIVATE_KEY }} | ||
# KNOWN_HOSTS: ${{ secrets.KNOWN_HOSTS }} | ||
# run: | | ||
# mkdir -p ~/.ssh | ||
# echo "$SSH_PRIVATE_KEY_NEW" > ~/.ssh/id_rsa | ||
# chmod 600 ~/.ssh/id_rsa | ||
# eval $(ssh-agent -s) | ||
# ssh-add ~/.ssh/id_rsa | ||
# echo "$KNOWN_HOSTS" > ~/.ssh/known_hosts | ||
|
||
|
||
# - name: Configure SSH for easier access | ||
# run: | | ||
# echo "Host staging-server" >> ~/.ssh/config | ||
# echo " HostName ${{ secrets.DO_IP_ADDRESS }}" >> ~/.ssh/config | ||
# echo " User ${{ secrets.DO_USERNAME }}" >> ~/.ssh/config | ||
# echo " IdentityFile ~/.ssh/id_rsa" >> ~/.ssh/config | ||
# echo " StrictHostKeyChecking no" >> ~/.ssh/config | ||
|
||
# - name: Deploy to DigitalOcean Droplet | ||
# run: | | ||
# ssh -o StrictHostKeyChecking=no -t staging-server << 'EOF' | ||
# set -e | ||
# cd ~/bluewave-onboarding | ||
# git stash | ||
# git pull | ||
# docker compose down | ||
# docker compose build | ||
# docker compose up -d | ||
# EOF | ||
name: Deploy to Staging | ||
|
||
on: | ||
push: | ||
branches: | ||
- staging | ||
|
||
jobs: | ||
deploy: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [22.x] | ||
|
||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
|
||
- name: Set up SSH | ||
env: | ||
SSH_PRIVATE_KEY_NEW: ${{ secrets.SSH_THIRD_PRIVATE_KEY }} | ||
KNOWN_HOSTS: ${{ secrets.KNOWN_HOSTS }} | ||
run: | | ||
mkdir -p ~/.ssh | ||
echo "$SSH_PRIVATE_KEY_NEW" > ~/.ssh/id_rsa | ||
chmod 600 ~/.ssh/id_rsa | ||
eval $(ssh-agent -s) | ||
ssh-add ~/.ssh/id_rsa | ||
echo "$KNOWN_HOSTS" > ~/.ssh/known_hosts | ||
- name: Configure SSH for easier access | ||
run: | | ||
echo "Host staging-server" >> ~/.ssh/config | ||
echo " HostName ${{ secrets.DO_IP_ADDRESS }}" >> ~/.ssh/config | ||
echo " User ${{ secrets.DO_USERNAME }}" >> ~/.ssh/config | ||
echo " IdentityFile ~/.ssh/id_rsa" >> ~/.ssh/config | ||
echo " StrictHostKeyChecking no" >> ~/.ssh/config | ||
- name: Deploy to DigitalOcean Droplet | ||
run: | | ||
ssh -o StrictHostKeyChecking=no -t staging-server << 'EOF' | ||
set -e | ||
cd ~/bluewave-onboarding | ||
git stash | ||
git pull | ||
git stash apply | ||
docker compose down | ||
docker compose build | ||
docker compose up -d | ||
EOF |
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
Binary file not shown.
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,11 +1,26 @@ | ||
# Node environment | ||
NODE_ENV=development | ||
|
||
# Development environment | ||
DEV_DB_USERNAME=user123 | ||
DEV_DB_PASSWORD=password123 | ||
DEV_DB_NAME=onboarding_db | ||
DEV_DB_HOST=localhost | ||
DEV_DB_PORT=5432 | ||
|
||
EMAIL_ENABLE=false | ||
# Node environment | ||
NODE_ENV=development | ||
|
||
# Development environment | ||
DEV_DB_USERNAME=user123 | ||
DEV_DB_PASSWORD=password123 | ||
DEV_DB_NAME=onboarding_db | ||
DEV_DB_HOST=db | ||
DEV_DB_PORT=5432 | ||
|
||
EMAIL_ENABLE=false | ||
|
||
# JWT Secret Key | ||
JWT_SECRET="NKrbO2lpCsOpVAlqAPsjZ0tZXzIoKru7gAmYZ7XlHn0=qqwqeq" | ||
|
||
TEST_DB_USERNAME=user123 | ||
TEST_DB_PASSWORD=password123 | ||
TEST_DB_NAME=onboarding_db_test | ||
TEST_DB_HOST=localhost | ||
TEST_DB_PORT=5432 | ||
|
||
ENABLE_IP_CHECK=false | ||
# Allowed IP range for the API "baseIp/rangeStart-rangeEnd" (e.g. 192.168.1/1-255) separated by comma | ||
ALLOWED_IP_RANGE=11.22.33/10-200, 192.168.65/1-255 | ||
# Allowed IP addresses for the API separated by comma | ||
ALLOWED_IPS=127.0.0.1, 11.22.33.44, 11.22.33.45, 11.22.33.46, 192.168.65.1 |
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,11 +1,21 @@ | ||
# Test Environment Configuration | ||
|
||
# Database Configuration | ||
TEST_DB_USERNAME=test_user | ||
TEST_DB_PASSWORD=test_password | ||
TEST_DB_NAME=test_db | ||
TEST_DB_USERNAME=user123 | ||
TEST_DB_PASSWORD=password123 | ||
TEST_DB_NAME=onboarding_db_test | ||
TEST_DB_HOST=localhost | ||
TEST_DB_PORT=5432 | ||
|
||
POSTGRES_USER=user123 | ||
POSTGRES_PASSWORD=password123 | ||
POSTGRES_DB=onboarding_db_test | ||
|
||
# JWT Secret Key | ||
JWT_SECRET=your_test_jwt_secret_key_here | ||
|
||
ENABLE_IP_CHECK=false | ||
# Allowed IP range for the API "baseIp/rangeStart-rangeEnd" (e.g. 192.168.1/1-255) separated by comma | ||
ALLOWED_IP_RANGE=11.22.33/10-200, 192.168.65/1-255 | ||
# Allowed IP addresses for the API separated by comma | ||
ALLOWED_IPS=127.0.0.1, 11.22.33.44, 11.22.33.45, 11.22.33.46, 192.168.65.1 |
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,3 +2,4 @@ node_modules/ | |
.env | ||
logs/ | ||
dist/ | ||
.nyc_output |
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,32 @@ | ||
const constants = require("../src/utils/constants.helper"); | ||
const userRole = constants.ROLE; | ||
|
||
module.exports = { | ||
user: { | ||
role: { | ||
'admin': userRole.ADMIN, | ||
'member': userRole.MEMBER | ||
}, | ||
roleEnum: [userRole.ADMIN, userRole.MEMBER], | ||
roleName: { | ||
[userRole.ADMIN]: 'admin', | ||
[userRole.MEMBER]: 'member' | ||
} | ||
}, | ||
team: { | ||
permissions: { | ||
invite: [userRole.ADMIN], | ||
removeUser: [userRole.ADMIN], | ||
update: [userRole.ADMIN], | ||
changeRole: [userRole.ADMIN], | ||
setOrg: [userRole.ADMIN], | ||
serverUrl: [userRole.ADMIN], | ||
popups: [userRole.ADMIN], | ||
hints: [userRole.ADMIN], | ||
banners: [userRole.ADMIN], | ||
links: [userRole.ADMIN], | ||
tours: [userRole.ADMIN], | ||
helpers: [userRole.ADMIN], | ||
} | ||
} | ||
}; |
Oops, something went wrong.