mirror of
https://github.com/standardnotes/server
synced 2026-01-17 05:04:27 -05:00
Compare commits
240 Commits
@standardn
...
@standardn
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e5eef3aba0 | ||
|
|
d261c81cd0 | ||
|
|
634e3bbb67 | ||
|
|
f8c9e67063 | ||
|
|
18eddea6f8 | ||
|
|
c6d655c5f5 | ||
|
|
46867c1a4d | ||
|
|
d29903bab6 | ||
|
|
3415cae093 | ||
|
|
408fd5a0c6 | ||
|
|
0a16ee64fe | ||
|
|
22b00479b4 | ||
|
|
5311e74266 | ||
|
|
5be7db7788 | ||
|
|
3bd1547ce3 | ||
|
|
a1fe15f7a9 | ||
|
|
19b8921f28 | ||
|
|
6b7879ba15 | ||
|
|
bd5f492a73 | ||
|
|
67311cc002 | ||
|
|
f39d3aca5b | ||
|
|
8e47491e3c | ||
|
|
0036d527bd | ||
|
|
f565f1d950 | ||
|
|
8e35dfa4b7 | ||
|
|
f911473be9 | ||
|
|
71624f1897 | ||
|
|
17de6ea7e1 | ||
|
|
6aad7cd207 | ||
|
|
63af335877 | ||
|
|
8cd7a138ab | ||
|
|
f69cdc7b03 | ||
|
|
2ca649cf31 | ||
|
|
f2ada08201 | ||
|
|
54ba1f69e5 | ||
|
|
f13a99f5fd | ||
|
|
e9bba6fd3a | ||
|
|
f0d1a70c87 | ||
|
|
56f0aef21d | ||
|
|
75e266cb9e | ||
|
|
b9bb83c0ce | ||
|
|
da645c5ab3 | ||
|
|
318af5757d | ||
|
|
b1cc156a25 | ||
|
|
79d71ca161 | ||
|
|
cedd50b366 | ||
|
|
0d5dcdd8ec | ||
|
|
d2b0fb144b | ||
|
|
053852b46c | ||
|
|
6ad349d379 | ||
|
|
f7d33c7164 | ||
|
|
b53b67328f | ||
|
|
573ffbfcf3 | ||
|
|
501ac0e99f | ||
|
|
959a11293a | ||
|
|
fee1f1a3a7 | ||
|
|
b0fbe0bb58 | ||
|
|
0087c70007 | ||
|
|
36e496dd7c | ||
|
|
f2e2030e85 | ||
|
|
0c3737dc19 | ||
|
|
f7471119e1 | ||
|
|
9bd97b95e9 | ||
|
|
b7400c198f | ||
|
|
f87036e3a8 | ||
|
|
a43e5ef724 | ||
|
|
913ced70b0 | ||
|
|
6ffce30a36 | ||
|
|
f5a57d886c | ||
|
|
e8ba49ecca | ||
|
|
c79a5dc94b | ||
|
|
4db83ae678 | ||
|
|
84ceb7ffd2 | ||
|
|
e215ac4343 | ||
|
|
bc8048790f | ||
|
|
886ccf84c1 | ||
|
|
c067cb9fe4 | ||
|
|
6b2389cdc3 | ||
|
|
d93916b159 | ||
|
|
c34f548e45 | ||
|
|
6fcd56cc86 | ||
|
|
8f88a87c93 | ||
|
|
f8c2f84322 | ||
|
|
46c4947871 | ||
|
|
64759ec2da | ||
|
|
5f7e768e64 | ||
|
|
4bc189f1c5 | ||
|
|
71721ab198 | ||
|
|
5536a48966 | ||
|
|
f77e29d3c9 | ||
|
|
4b1fc718a2 | ||
|
|
1708c3f8a0 | ||
|
|
352e02028d | ||
|
|
1bbb639c83 | ||
|
|
c14265f103 | ||
|
|
c030a6b3d8 | ||
|
|
af997ea658 | ||
|
|
efa4d7fc60 | ||
|
|
f714aaa0e9 | ||
|
|
aee6e60583 | ||
|
|
4e602687d5 | ||
|
|
d026152ac8 | ||
|
|
3f21a358d2 | ||
|
|
dc55e47c98 | ||
|
|
3b804e2321 | ||
|
|
b32f851a90 | ||
|
|
479d20e76f | ||
|
|
fae4553fc8 | ||
|
|
cb74b23e45 | ||
|
|
af8f12c33a | ||
|
|
a148c4d1f6 | ||
|
|
f7190c0c9c | ||
|
|
c00d7765a9 | ||
|
|
2b651d86e2 | ||
|
|
9be3517093 | ||
|
|
fcfedaf7e7 | ||
|
|
0b82794e9c | ||
|
|
2a52e398cb | ||
|
|
c31e882ad2 | ||
|
|
2f0903e0eb | ||
|
|
2396053bc1 | ||
|
|
17fd12305e | ||
|
|
425ea4374d | ||
|
|
c076c3c74a | ||
|
|
547cdfd8ec | ||
|
|
a0af8f0025 | ||
|
|
c970b1ea68 | ||
|
|
4d1e2dec26 | ||
|
|
108408a944 | ||
|
|
18d07d431f | ||
|
|
cbc024f67a | ||
|
|
55ec5970da | ||
|
|
58bdca6659 | ||
|
|
ef49b0d3f8 | ||
|
|
9cb691e5ad | ||
|
|
04d09582d4 | ||
|
|
8f90dc172b | ||
|
|
f759261919 | ||
|
|
2606f6d929 | ||
|
|
c288e5d8dc | ||
|
|
4b76d4b71e | ||
|
|
72310130d2 | ||
|
|
f9e51ef06e | ||
|
|
92a5eb0d98 | ||
|
|
77d2ea1a1f | ||
|
|
92f96ddb84 | ||
|
|
15a914e25e | ||
|
|
912a29d091 | ||
|
|
b2c32ce70e | ||
|
|
ed1a708c40 | ||
|
|
e905128d45 | ||
|
|
fd598f372a | ||
|
|
7a3946a9e2 | ||
|
|
cbdd2584d0 | ||
|
|
f3161c2712 | ||
|
|
148542dd5a | ||
|
|
d2b2c339f2 | ||
|
|
d2578c48f0 | ||
|
|
fecfd54728 | ||
|
|
17e4162d3e | ||
|
|
742209d773 | ||
|
|
1fa4b7cf27 | ||
|
|
5dc5507039 | ||
|
|
3035a20b9f | ||
|
|
04b3bb034f | ||
|
|
bf84be0136 | ||
|
|
890cf48749 | ||
|
|
2b3436c6ce | ||
|
|
4df8c3b2e5 | ||
|
|
25a2696c32 | ||
|
|
52f879f842 | ||
|
|
4f70fa156d | ||
|
|
38e77f04be | ||
|
|
060206ddd4 | ||
|
|
0bc0909386 | ||
|
|
667d528a8c | ||
|
|
fa7fbe26e7 | ||
|
|
ba422a29d0 | ||
|
|
d220ec5bf7 | ||
|
|
7baf5492bc | ||
|
|
d5a8409bb5 | ||
|
|
f58f90667c | ||
|
|
a388e1a802 | ||
|
|
8811d10a73 | ||
|
|
c7a394cd1a | ||
|
|
b7615a7f2e | ||
|
|
1ca70c1e50 | ||
|
|
253cbb1d0c | ||
|
|
e38a16404c | ||
|
|
f17a1f875c | ||
|
|
2237e0f5df | ||
|
|
0df471585f | ||
|
|
95aac1a7bf | ||
|
|
c078bc958d | ||
|
|
49c27924ea | ||
|
|
c9dd8e7338 | ||
|
|
5ef90cc75b | ||
|
|
063c61d96c | ||
|
|
0cb5e36b20 | ||
|
|
319bab5b34 | ||
|
|
90a4f2111f | ||
|
|
3aba202970 | ||
|
|
c8974b7fa2 | ||
|
|
3654a19586 | ||
|
|
5f0929c1aa | ||
|
|
c0fa83bce6 | ||
|
|
c201ee42a0 | ||
|
|
e6a4cc3098 | ||
|
|
39f2fe2ba1 | ||
|
|
72ce190996 | ||
|
|
527dd1b61b | ||
|
|
af8feaadfe | ||
|
|
3164f76662 | ||
|
|
d6e531d4b6 | ||
|
|
af76878dad | ||
|
|
28cce39fe7 | ||
|
|
a8b806af08 | ||
|
|
fa0b0294b4 | ||
|
|
58ab410b0a | ||
|
|
51c8b20506 | ||
|
|
1e62a3760e | ||
|
|
2f569d4104 | ||
|
|
f23e444ed0 | ||
|
|
e6e9a32f03 | ||
|
|
8237df33a7 | ||
|
|
624b574013 | ||
|
|
d762bc89d1 | ||
|
|
f0cbec07b8 | ||
|
|
8c1f583968 | ||
|
|
b28636fa73 | ||
|
|
092054fd44 | ||
|
|
9391917d08 | ||
|
|
5cf008f53d | ||
|
|
231194bd53 | ||
|
|
2707e87554 | ||
|
|
4b40c59e7e | ||
|
|
f2e8579f95 | ||
|
|
57118c85e3 | ||
|
|
8ddc7b0a58 | ||
|
|
bc63d0aeea |
1
.github/ci.env
vendored
1
.github/ci.env
vendored
@@ -4,6 +4,7 @@ DB_USERNAME=std_notes_user
|
||||
DB_PASSWORD=changeme123
|
||||
DB_DATABASE=standard_notes_db
|
||||
DB_PORT=3306
|
||||
DB_SQLITE_DATABASE_PATH=standard_notes_db
|
||||
REDIS_PORT=6379
|
||||
REDIS_HOST=cache
|
||||
AUTH_SERVER_ACCESS_TOKEN_AGE=4
|
||||
|
||||
60
.github/workflows/common-e2e.yml
vendored
60
.github/workflows/common-e2e.yml
vendored
@@ -37,6 +37,9 @@ jobs:
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
node-version-file: '.nvmrc'
|
||||
|
||||
- name: Install
|
||||
run: yarn install --immutable
|
||||
|
||||
- name: Run Server
|
||||
run: docker compose -f docker-compose.ci.yml up -d
|
||||
env:
|
||||
@@ -47,10 +50,31 @@ jobs:
|
||||
run: docker/is-available.sh http://localhost:3123 $(pwd)/logs
|
||||
|
||||
- name: Run E2E Test Suite
|
||||
run: yarn dlx mocha-headless-chrome --timeout 1200000 -f http://localhost:9001/mocha/test.html
|
||||
run: yarn dlx mocha-headless-chrome --timeout 1800000 -f http://localhost:9001/mocha/test.html
|
||||
|
||||
- name: Show logs on failure
|
||||
if: ${{ failure() }}
|
||||
run: |
|
||||
echo "# Errors:"
|
||||
tail -n 100 logs/*.err
|
||||
echo "# Logs:"
|
||||
tail -n 100 logs/*.log
|
||||
|
||||
e2e-home-server:
|
||||
name: (Home Server) E2E Test Suite
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
db_type: [mysql, sqlite]
|
||||
cache_type: [redis, memory]
|
||||
include:
|
||||
- cache_type: redis
|
||||
db_type: mysql
|
||||
redis_port: 6380
|
||||
- cache_type: redis
|
||||
db_type: sqlite
|
||||
redis_port: 6381
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
services:
|
||||
@@ -58,6 +82,19 @@ jobs:
|
||||
image: standardnotes/snjs:${{ inputs.snjs_image_tag }}
|
||||
ports:
|
||||
- 9001:9001
|
||||
cache:
|
||||
image: redis
|
||||
ports:
|
||||
- ${{ matrix.redis_port }}:6379
|
||||
db:
|
||||
image: mysql
|
||||
ports:
|
||||
- 3307:3306
|
||||
env:
|
||||
MYSQL_ROOT_PASSWORD: root
|
||||
MYSQL_DATABASE: standardnotes_${{ matrix.cache_type }}
|
||||
MYSQL_USER: standardnotes
|
||||
MYSQL_PASSWORD: standardnotes
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
@@ -85,11 +122,22 @@ jobs:
|
||||
sed -i "s/PSEUDO_KEY_PARAMS_KEY=/PSEUDO_KEY_PARAMS_KEY=$(openssl rand -hex 32)/g" packages/home-server/.env
|
||||
sed -i "s/VALET_TOKEN_SECRET=/VALET_TOKEN_SECRET=$(openssl rand -hex 32)/g" packages/home-server/.env
|
||||
echo "ACCESS_TOKEN_AGE=4" >> packages/home-server/.env
|
||||
echo "REFRESH_TOKEN_AGE=7" >> packages/home-server/.env
|
||||
echo "REFRESH_TOKEN_AGE=10" >> packages/home-server/.env
|
||||
echo "REVISIONS_FREQUENCY=5" >> packages/home-server/.env
|
||||
echo "DB_HOST=localhost" >> packages/home-server/.env
|
||||
echo "DB_PORT=3307" >> packages/home-server/.env
|
||||
echo "DB_DATABASE=standardnotes_${{ matrix.cache_type }}" >> packages/home-server/.env
|
||||
echo "DB_SQLITE_DATABASE_PATH=sqlite_${{ matrix.cache_type }}.db" >> packages/home-server/.env
|
||||
echo "DB_USERNAME=standardnotes" >> packages/home-server/.env
|
||||
echo "DB_PASSWORD=standardnotes" >> packages/home-server/.env
|
||||
echo "DB_TYPE=${{ matrix.db_type }}" >> packages/home-server/.env
|
||||
echo "REDIS_URL=redis://localhost:${{ matrix.redis_port }}" >> packages/home-server/.env
|
||||
echo "CACHE_TYPE=${{ matrix.cache_type }}" >> packages/home-server/.env
|
||||
echo "FILES_SERVER_URL=http://localhost:3123" >> packages/home-server/.env
|
||||
echo "E2E_TESTING=true" >> packages/home-server/.env
|
||||
|
||||
- name: Run Server
|
||||
run: nohup yarn workspace @standardnotes/home-server start &
|
||||
run: nohup yarn workspace @standardnotes/home-server start > logs/output.log 2>&1 &
|
||||
env:
|
||||
PORT: 3123
|
||||
|
||||
@@ -97,4 +145,8 @@ jobs:
|
||||
run: for i in {1..30}; do curl -s http://localhost:3123/healthcheck && break || sleep 1; done
|
||||
|
||||
- name: Run E2E Test Suite
|
||||
run: yarn dlx mocha-headless-chrome --timeout 1200000 -f http://localhost:9001/mocha/test.html?skip_paid_features=true
|
||||
run: yarn dlx mocha-headless-chrome --timeout 1800000 -f http://localhost:9001/mocha/test.html
|
||||
|
||||
- name: Show logs on failure
|
||||
if: ${{ failure() }}
|
||||
run: tail -n 500 logs/output.log
|
||||
|
||||
9
.github/workflows/pr.yml
vendored
9
.github/workflows/pr.yml
vendored
@@ -25,6 +25,9 @@ jobs:
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
node-version-file: '.nvmrc'
|
||||
|
||||
- name: Install
|
||||
run: yarn install --immutable
|
||||
|
||||
- name: Build
|
||||
run: yarn build
|
||||
|
||||
@@ -50,6 +53,9 @@ jobs:
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
node-version-file: '.nvmrc'
|
||||
|
||||
- name: Install
|
||||
run: yarn install --immutable
|
||||
|
||||
- name: Build
|
||||
if: steps.cache-build.outputs.cache-hit != 'true'
|
||||
run: yarn build
|
||||
@@ -79,6 +85,9 @@ jobs:
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
node-version-file: '.nvmrc'
|
||||
|
||||
- name: Install
|
||||
run: yarn install --immutable
|
||||
|
||||
- name: Build
|
||||
if: steps.cache-build.outputs.cache-hit != 'true'
|
||||
run: yarn build
|
||||
|
||||
26
.github/workflows/publish.yml
vendored
26
.github/workflows/publish.yml
vendored
@@ -25,6 +25,9 @@ jobs:
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
node-version-file: '.nvmrc'
|
||||
|
||||
- name: Install
|
||||
run: yarn install --immutable
|
||||
|
||||
- name: Build
|
||||
run: yarn build
|
||||
|
||||
@@ -50,6 +53,9 @@ jobs:
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
node-version-file: '.nvmrc'
|
||||
|
||||
- name: Install
|
||||
run: yarn install --immutable
|
||||
|
||||
- name: Build
|
||||
if: steps.cache-build.outputs.cache-hit != 'true'
|
||||
run: yarn build
|
||||
@@ -79,6 +85,9 @@ jobs:
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
node-version-file: '.nvmrc'
|
||||
|
||||
- name: Install
|
||||
run: yarn install --immutable
|
||||
|
||||
- name: Build
|
||||
if: steps.cache-build.outputs.cache-hit != 'true'
|
||||
run: yarn build
|
||||
@@ -86,20 +95,20 @@ jobs:
|
||||
- name: Test
|
||||
run: yarn test
|
||||
|
||||
e2e:
|
||||
needs: build
|
||||
name: E2E
|
||||
uses: standardnotes/server/.github/workflows/common-e2e.yml@main
|
||||
secrets: inherit
|
||||
# e2e:
|
||||
# needs: build
|
||||
# name: E2E
|
||||
# uses: standardnotes/server/.github/workflows/common-e2e.yml@main
|
||||
# secrets: inherit
|
||||
|
||||
publish-self-hosting:
|
||||
needs: [ test, lint, e2e ]
|
||||
needs: [ test, lint ]
|
||||
name: Publish Self Hosting Docker Image
|
||||
uses: standardnotes/server/.github/workflows/common-self-hosting.yml@main
|
||||
secrets: inherit
|
||||
|
||||
publish-services:
|
||||
needs: [ test, lint, e2e ]
|
||||
needs: [ test, lint ]
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
@@ -137,6 +146,9 @@ jobs:
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
node-version-file: '.nvmrc'
|
||||
|
||||
- name: Install
|
||||
run: yarn install --immutable
|
||||
|
||||
- name: Build
|
||||
if: steps.cache-build.outputs.cache-hit != 'true'
|
||||
run: yarn build
|
||||
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -11,7 +11,6 @@ newrelic_agent.log
|
||||
!.yarn/patches
|
||||
!.yarn/plugins
|
||||
!.yarn/releases
|
||||
!.yarn/unplugged
|
||||
!.yarn/sdks
|
||||
!.yarn/versions
|
||||
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-client-s3-npm-3.342.0-a2692091c5-9f3b9171dd.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-client-s3-npm-3.342.0-a2692091c5-9f3b9171dd.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-client-sns-npm-3.342.0-94ce02a19b-8d7ccac0ed.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-client-sns-npm-3.342.0-94ce02a19b-8d7ccac0ed.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-client-sqs-npm-3.342.0-f4e06f69ac-e08dd27f26.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-client-sqs-npm-3.342.0-f4e06f69ac-e08dd27f26.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-client-sso-npm-3.342.0-be2d1dcabe-78748ec6a8.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-client-sso-npm-3.342.0-be2d1dcabe-78748ec6a8.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-client-sso-oidc-npm-3.342.0-ead49d3554-083c2beff3.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-client-sso-oidc-npm-3.342.0-ead49d3554-083c2beff3.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-client-sts-npm-3.342.0-ccdc6f5bcc-14475bf1b4.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-client-sts-npm-3.342.0-ccdc6f5bcc-14475bf1b4.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-eventstream-codec-npm-3.342.0-599f1c19f8-b735b3ea18.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-eventstream-codec-npm-3.342.0-599f1c19f8-b735b3ea18.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-signing-npm-3.342.0-e6a817dad1-ccbede8d93.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-signing-npm-3.342.0-e6a817dad1-ccbede8d93.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user