Repository navigation
146 lines (143 loc) · 6.67 KB
/
Copy pathdatabase-upgrade.yml
File metadata and controls
146 lines (143 loc) · 6.67 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
name: Database upgrade
on:
pull_request:
paths:
- "packages/db/**"
- "apps/server/src/services/plugin-storage.ts"
- "apps/server/src/services/plugin-databases.ts"
- "apps/server/src/plugins/manager.ts"
- "tests/plugin-managed-storage.test.ts"
- "tests/plugin-databases.test.ts"
- "tests/plugin-manager.test.ts"
- "tests/plugin-credentials.test.ts"
- "tests/schema-reconciliation*.test.ts"
- "tests/schema-column-alignment.test.ts"
- "tests/site-logo.test.ts"
- "apps/server/src/routes/site-branding.ts"
- "apps/server/src/services/site-logo.ts"
- "tests/database.ts"
- "tests/mcp*.test.ts"
- "tests/browser-*.test.ts"
- "apps/server/src/routes/browser-*.ts"
- "apps/server/src/services/browser-*.ts"
- "packages/core/src/modules/browser-clipper/**"
- "apps/server/src/routes/ai-mcp.ts"
- "apps/server/src/routes/mcp-management.ts"
- "apps/server/src/services/ai/mcp-*.ts"
- "tests/editor-package-upgrade.test.ts"
- "tests/sheet-package-upgrade.test.ts"
- "tests/knowledge-book*.test.ts"
- "packages/core/src/modules/knowledge-books/**"
- "apps/server/src/services/knowledge-book-storage-maintenance.ts"
- "tests/user-groups.test.ts"
- "tests/user-groups-schema.test.ts"
- "packages/core/src/modules/groups/**"
- "tests/folder-sharing.test.ts"
- "tests/resource-handover.test.ts"
- "packages/core/src/modules/identity/resource-handover.ts"
- "apps/server/src/routes/resource-handover.ts"
- "tests/files.test.ts"
- "tests/file-trash-clear.test.ts"
- "apps/server/src/services/file-trash-clear.ts"
- "tests/ai-session-source.test.ts"
- "tests/community.test.ts"
- "tests/ai-source-lifecycle.test.ts"
- "package.json"
- "pnpm-lock.yaml"
- "scripts/verify-mcp-execution-decoupling.mts"
- ".github/workflows/database-upgrade.yml"
push:
branches: [main]
paths:
- "packages/db/**"
- "apps/server/src/services/plugin-storage.ts"
- "apps/server/src/services/plugin-databases.ts"
- "apps/server/src/plugins/manager.ts"
- "tests/plugin-managed-storage.test.ts"
- "tests/plugin-databases.test.ts"
- "tests/plugin-manager.test.ts"
- "tests/plugin-credentials.test.ts"
- "tests/schema-reconciliation*.test.ts"
- "tests/schema-column-alignment.test.ts"
- "tests/site-logo.test.ts"
- "apps/server/src/routes/site-branding.ts"
- "apps/server/src/services/site-logo.ts"
- "tests/database.ts"
- "tests/mcp*.test.ts"
- "tests/browser-*.test.ts"
- "apps/server/src/routes/browser-*.ts"
- "apps/server/src/services/browser-*.ts"
- "packages/core/src/modules/browser-clipper/**"
- "apps/server/src/routes/ai-mcp.ts"
- "apps/server/src/routes/mcp-management.ts"
- "apps/server/src/services/ai/mcp-*.ts"
- "tests/editor-package-upgrade.test.ts"
- "tests/sheet-package-upgrade.test.ts"
- "tests/knowledge-book*.test.ts"
- "packages/core/src/modules/knowledge-books/**"
- "apps/server/src/services/knowledge-book-storage-maintenance.ts"
- "tests/user-groups.test.ts"
- "tests/user-groups-schema.test.ts"
- "packages/core/src/modules/groups/**"
- "tests/folder-sharing.test.ts"
- "tests/resource-handover.test.ts"
- "packages/core/src/modules/identity/resource-handover.ts"
- "apps/server/src/routes/resource-handover.ts"
- "tests/files.test.ts"
- "tests/file-trash-clear.test.ts"
- "apps/server/src/services/file-trash-clear.ts"
- "tests/ai-session-source.test.ts"
- "tests/community.test.ts"
- "tests/ai-source-lifecycle.test.ts"
- "package.json"
- "pnpm-lock.yaml"
- "scripts/verify-mcp-execution-decoupling.mts"
- ".github/workflows/database-upgrade.yml"
permissions:
contents: read
jobs:
postgres:
name: PostgreSQL ${{ matrix.version }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
version: [17, 18]
services:
postgres:
image: postgres:${{ matrix.version }}
env:
POSTGRES_DB: doca_test
POSTGRES_USER: postgres
POSTGRES_PASSWORD: isolated-test
ports:
- 5432:5432
options: >-
--health-cmd "pg_isready -U postgres -d doca_test"
--health-interval 5s
--health-timeout 5s
--health-retries 10
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-node@v4
with:
node-version: "22"
- name: Enable pnpm
run: corepack enable && corepack prepare pnpm@11.25.0 --activate
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Verify isolated upgrades and folder sharing
env:
DOCA_TEST_POSTGRES: postgres://postgres:isolated-test@127.0.0.1:5432/doca_test
run: pnpm exec vitest run tests/user-groups.test.ts tests/user-groups-schema.test.ts tests/permissions-v2.test.ts tests/permission-inheritance.test.ts tests/site-logo.test.ts tests/schema-column-alignment.test.ts tests/schema-reconciliation-postgres.test.ts tests/mcp.test.ts tests/mcp-schema.test.ts tests/mcp-execution-schema.test.ts tests/folder-sharing.test.ts tests/resource-handover.test.ts tests/files.test.ts tests/knowledge-books.test.ts tests/knowledge-book-payload-storage.test.ts tests/knowledge-book-batch-checkpoints.test.ts tests/knowledge-book-checkpoint-runtime.test.ts tests/knowledge-book-startup-upgrade.test.ts tests/plugin-managed-storage.test.ts tests/plugin-databases.test.ts tests/plugin-postgres-permissions.test.ts tests/plugin-manager.test.ts tests/plugin-selection.test.ts tests/plugin-credentials.test.ts tests/editor-package-upgrade.test.ts tests/sheet-package-upgrade.test.ts tests/browser-clipper.test.ts tests/browser-clipper-schema.test.ts tests/browser-assistant.test.ts tests/browser-assistant-empty-scope.test.ts tests/file-trash-clear.test.ts tests/ai-session-source.test.ts tests/ai-source-lifecycle.test.ts tests/community.test.ts --maxWorkers=2
- name: Upgrade actual released 0.2.29 data without conversion
env:
DOCA_QA_ISOLATED: "1"
DOCA_TEST_POSTGRES: postgres://postgres:isolated-test@127.0.0.1:5432/doca_test
run: pnpm exec tsx scripts/verify-mcp-execution-decoupling.mts postgres
- name: Verify QR sign-in and its additive schema change
env:
DOCA_TEST_POSTGRES: postgres://postgres:isolated-test@127.0.0.1:5432/doca_test
run: pnpm exec vitest run tests/mobile-session.test.ts tests/qr-login-schema.test.ts --maxWorkers=2