Skip to content

Commit f44412f

Browse files
committed
Merge branch 'main' into ci-cd-aws-deploy
2 parents ef9d448 + dea4987 commit f44412f

File tree

90 files changed

+9069
-371
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

90 files changed

+9069
-371
lines changed

.env.sample

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,10 @@ COLLAB_DB_LOCAL_URI=mongodb://collaboration-db:27017/collaboration-service
2424
YJS_DB_CLOUD_URI=mongodb+srv://<username>:<password>@cluster0.h5ukw.mongodb.net/yjs-documents?retryWrites=true&w=majority&appName=Cluster0
2525
YJS_DB_LOCAL_URI=mongodb://collaboration-db:27017/yjs-documents
2626

27+
# History Service
28+
HISTORY_DB_CLOUD_URI=<FILL-THIS-IN>
29+
HISTORY_DB_LOCAL_URI=mongodb://history-db:27017/history
30+
2731
# Will use cloud MongoDB Atlas database
2832
ENV=PROD
2933

.github/workflows/tests.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,3 +36,22 @@ jobs:
3636
run: cd ${{ matrix.service }} && npm run lint
3737
- name: Build App
3838
run: cd ${{ matrix.service }} && npm run build
39+
40+
41+
build-history:
42+
runs-on: ubuntu-latest
43+
timeout-minutes: 60
44+
steps:
45+
- uses: actions/checkout@v4
46+
- name: Use Node.js
47+
uses: actions/setup-node@v4
48+
with:
49+
node-version: ${{ env.node-version }}
50+
- name: Install Node Modules
51+
run: cd services/history && npm ci
52+
- name: Linting
53+
run: cd services/history && npm run lint
54+
- name: Build App
55+
run: cd services/history && npm run build
56+
- name: Run tests
57+
run: cd services/history && npm run test

compose.dev.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,26 @@ services:
4747
volumes:
4848
- /app/node_modules
4949
- ./services/collaboration:/app
50+
51+
collaboration-db:
52+
ports:
53+
- 27020:27017
54+
55+
collaboration-db:
56+
ports:
57+
- 27020:27017
58+
59+
history:
60+
command: npm run dev
61+
ports:
62+
- 8086:8086
63+
volumes:
64+
- /app/node_modules
65+
- ./services/history:/app
66+
67+
history-db:
68+
ports:
69+
- 27021:27017
5070

5171
broker:
5272
ports:

compose.yml

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ services:
2121
- user
2222
- match
2323
- collaboration
24+
- history
2425
networks:
2526
- gateway-network
2627
restart: always
@@ -167,12 +168,39 @@ services:
167168
networks:
168169
- collaboration-db-network
169170
restart: always
171+
172+
history:
173+
container_name: history
174+
image: history
175+
build:
176+
context: services/history
177+
dockerfile: Dockerfile
178+
environment:
179+
DB_CLOUD_URI: ${HISTORY_DB_CLOUD_URI}
180+
DB_LOCAL_URI: ${HISTORY_DB_LOCAL_URI}
181+
BROKER_URL: ${BROKER_URL}
182+
JWT_SECRET: ${JWT_SECRET}
183+
depends_on:
184+
broker:
185+
condition: service_healthy
186+
networks:
187+
- gateway-network
188+
- history-db-network
189+
190+
history-db:
191+
container_name: history-db
192+
image: mongo:7.0.14
193+
volumes:
194+
- history-db:/data/db
195+
networks:
196+
- history-db-network
170197

171198
volumes:
172199
question-db:
173200
user-db:
174201
match-db:
175202
collaboration-db:
203+
history-db:
176204

177205
networks:
178206
gateway-network:
@@ -184,4 +212,6 @@ networks:
184212
match-db-network:
185213
driver: bridge
186214
collaboration-db-network:
187-
driver: bridge
215+
driver: bridge
216+
history-db-network:
217+
driver: bridge

frontend/angular.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@
3737
"budgets": [
3838
{
3939
"type": "initial",
40-
"maximumWarning": "2MB",
41-
"maximumError": "3MB"
40+
"maximumWarning": "7MB",
41+
"maximumError": "10MB"
4242
},
4343
{
4444
"type": "anyComponentStyle",

0 commit comments

Comments
 (0)