Compare commits

..

1 Commits

Author SHA1 Message Date
Aman Harwara 84cbeaf3be chore: release latest code 2025-04-29 13:07:38 +02:00
263 changed files with 1405 additions and 4608 deletions
-3
View File
@@ -33,6 +33,3 @@ VALET_TOKEN_SECRET=4b886819ebe1e908077c6cae96311b48a8416bd60cc91c03060e15bdf6b30
SYNCING_SERVER_CONTENT_SIZE_TRANSFER_LIMIT=100000 SYNCING_SERVER_CONTENT_SIZE_TRANSFER_LIMIT=100000
HTTP_REQUEST_PAYLOAD_LIMIT_MEGABYTES=1 HTTP_REQUEST_PAYLOAD_LIMIT_MEGABYTES=1
APPLICATION_VERSION_THRESHOLD_FOR_TOKEN_VERSION_2=0.0.0
APPLICATION_VERSION_THRESHOLD_FOR_TOKEN_VERSION_3=0.0.0
+53 -60
View File
@@ -27,7 +27,7 @@ jobs:
snjs: snjs:
image: standardnotes/snjs:${{ inputs.snjs_image_tag }} image: standardnotes/snjs:${{ inputs.snjs_image_tag }}
ports: ports:
- 9001:9001 - 9001:9001
cache: cache:
image: redis image: redis
ports: ports:
@@ -43,71 +43,64 @@ jobs:
MYSQL_PASSWORD: standardnotes MYSQL_PASSWORD: standardnotes
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- name: Set up Node - name: Set up Node
uses: actions/setup-node@v4 uses: actions/setup-node@v4
with: with:
registry-url: 'https://registry.npmjs.org' registry-url: 'https://registry.npmjs.org'
node-version-file: '.nvmrc' node-version-file: '.nvmrc'
- name: Install Dependencies - name: Install Dependencies
run: yarn install --immutable run: yarn install --immutable
- name: Build - name: Build
run: yarn build run: yarn build
- name: Copy dotenv file - name: Copy dotenv file
run: cp packages/home-server/.env.sample packages/home-server/.env run: cp packages/home-server/.env.sample packages/home-server/.env
- name: Fill in env variables - name: Fill in env variables
run: | run: |
sed -i "s/JWT_SECRET=/JWT_SECRET=$(openssl rand -hex 32)/g" packages/home-server/.env sed -i "s/JWT_SECRET=/JWT_SECRET=$(openssl rand -hex 32)/g" packages/home-server/.env
sed -i "s/AUTH_JWT_SECRET=/AUTH_JWT_SECRET=$(openssl rand -hex 32)/g" packages/home-server/.env sed -i "s/AUTH_JWT_SECRET=/AUTH_JWT_SECRET=$(openssl rand -hex 32)/g" packages/home-server/.env
sed -i "s/ENCRYPTION_SERVER_KEY=/ENCRYPTION_SERVER_KEY=$(openssl rand -hex 32)/g" packages/home-server/.env sed -i "s/ENCRYPTION_SERVER_KEY=/ENCRYPTION_SERVER_KEY=$(openssl rand -hex 32)/g" packages/home-server/.env
sed -i "s/PSEUDO_KEY_PARAMS_KEY=/PSEUDO_KEY_PARAMS_KEY=$(openssl rand -hex 32)/g" packages/home-server/.env 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 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 "ACCESS_TOKEN_AGE=4" >> packages/home-server/.env
echo "REFRESH_TOKEN_AGE=10" >> packages/home-server/.env echo "REFRESH_TOKEN_AGE=10" >> packages/home-server/.env
echo "REVISIONS_FREQUENCY=2" >> packages/home-server/.env echo "REVISIONS_FREQUENCY=2" >> packages/home-server/.env
echo "CONTENT_SIZE_TRANSFER_LIMIT=100000" >> packages/home-server/.env echo "CONTENT_SIZE_TRANSFER_LIMIT=100000" >> packages/home-server/.env
echo "HTTP_REQUEST_PAYLOAD_LIMIT_MEGABYTES=1" >> packages/home-server/.env echo "HTTP_REQUEST_PAYLOAD_LIMIT_MEGABYTES=1" >> packages/home-server/.env
echo "DB_HOST=localhost" >> packages/home-server/.env echo "DB_HOST=localhost" >> packages/home-server/.env
echo "DB_PORT=3306" >> packages/home-server/.env echo "DB_PORT=3306" >> packages/home-server/.env
echo "DB_DATABASE=standardnotes" >> packages/home-server/.env echo "DB_DATABASE=standardnotes" >> packages/home-server/.env
echo "DB_SQLITE_DATABASE_PATH=homeserver.db" >> packages/home-server/.env echo "DB_SQLITE_DATABASE_PATH=homeserver.db" >> packages/home-server/.env
echo "DB_USERNAME=standardnotes" >> packages/home-server/.env echo "DB_USERNAME=standardnotes" >> packages/home-server/.env
echo "DB_PASSWORD=standardnotes" >> packages/home-server/.env echo "DB_PASSWORD=standardnotes" >> packages/home-server/.env
echo "DB_TYPE=${{ matrix.db_type }}" >> packages/home-server/.env echo "DB_TYPE=${{ matrix.db_type }}" >> packages/home-server/.env
echo "DB_DEBUG_LEVEL=all" >> packages/home-server/.env echo "DB_DEBUG_LEVEL=all" >> packages/home-server/.env
echo "REDIS_URL=redis://localhost:6379" >> packages/home-server/.env echo "REDIS_URL=redis://localhost:6379" >> packages/home-server/.env
echo "CACHE_TYPE=${{ matrix.cache_type }}" >> 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 "FILES_SERVER_URL=http://localhost:3123" >> packages/home-server/.env
echo "E2E_TESTING=true" >> packages/home-server/.env echo "E2E_TESTING=true" >> packages/home-server/.env
echo "APPLICATION_VERSION_THRESHOLD_FOR_TOKEN_VERSION_2=0.0.0" >> packages/home-server/.env
echo "APPLICATION_VERSION_THRESHOLD_FOR_TOKEN_VERSION_3=0.0.0" >> packages/home-server/.env
- name: Run Server - name: Run Server
run: nohup yarn workspace @standardnotes/home-server start > logs/output.log 2>&1 & run: nohup yarn workspace @standardnotes/home-server start > logs/output.log 2>&1 &
env: env:
PORT: 3123 PORT: 3123
- name: Wait for server to start - name: Wait for server to start
run: for i in {1..30}; do curl -s http://localhost:3123/healthcheck && break || sleep 1; done run: for i in {1..30}; do curl -s http://localhost:3123/healthcheck && break || sleep 1; done
- name: Run E2E Test Suite - name: Run E2E Test Suite
run: | run: yarn dlx mocha-headless-chrome --timeout 3600000 -a no-sandbox -a disable-setuid-sandbox -f http://localhost:9001/mocha/test.html?suite=${{ inputs.suite }}
TEST_URL="http://localhost:9001/mocha/test.html?suite=${{ inputs.suite }}"
if [ "${{ matrix.cache_type }}" = "memory" ]; then
TEST_URL="${TEST_URL}&skipSessionCooldownTests=true"
fi
yarn dlx mocha-headless-chrome@4.0.0 --timeout 3600000 --polling 1000 -a no-sandbox -a disable-setuid-sandbox -f "${TEST_URL}"
- name: Archive failed run logs - name: Archive failed run logs
if: ${{ failure() }} if: ${{ failure() }}
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
name: home-server-failure-logs-${{ inputs.suite }}-${{ matrix.db_type }}-${{ matrix.cache_type }} name: home-server-failure-logs-${{ inputs.suite }}-${{ matrix.db_type }}-${{ matrix.cache_type }}
retention-days: 5 retention-days: 5
path: | path: |
logs/output.log logs/output.log
+34 -34
View File
@@ -25,46 +25,46 @@ jobs:
snjs: snjs:
image: standardnotes/snjs:${{ inputs.snjs_image_tag }} image: standardnotes/snjs:${{ inputs.snjs_image_tag }}
ports: ports:
- 9001:9001 - 9001:9001
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- name: Set up Node - name: Set up Node
uses: actions/setup-node@v4 uses: actions/setup-node@v4
with: with:
registry-url: 'https://registry.npmjs.org' registry-url: 'https://registry.npmjs.org'
node-version-file: '.nvmrc' node-version-file: '.nvmrc'
- name: Install - name: Install
run: yarn install --immutable run: yarn install --immutable
- name: Run Server - name: Run Server
run: docker compose -f docker-compose.ci.yml up -d run: docker compose -f docker-compose.ci.yml up -d
env: env:
DB_TYPE: mysql DB_TYPE: mysql
CACHE_TYPE: redis CACHE_TYPE: redis
SERVICE_PROXY_TYPE: ${{ matrix.service_proxy_type }} SERVICE_PROXY_TYPE: ${{ matrix.service_proxy_type }}
- name: Output Server Logs to File - name: Output Server Logs to File
run: docker compose -f docker-compose.ci.yml logs -f > logs/docker-compose.log 2>&1 & run: docker compose -f docker-compose.ci.yml logs -f > logs/docker-compose.log 2>&1 &
env: env:
DB_TYPE: mysql DB_TYPE: mysql
CACHE_TYPE: redis CACHE_TYPE: redis
SERVICE_PROXY_TYPE: ${{ matrix.service_proxy_type }} SERVICE_PROXY_TYPE: ${{ matrix.service_proxy_type }}
- name: Wait for server to start - name: Wait for server to start
run: docker/is-available.sh http://localhost:3123 $(pwd)/logs run: docker/is-available.sh http://localhost:3123 $(pwd)/logs
- name: Run E2E Test Suite - name: Run E2E Test Suite
run: yarn dlx mocha-headless-chrome@4.0.0 --timeout 3600000 --polling 1000 -a no-sandbox -a disable-setuid-sandbox -f http://localhost:9001/mocha/test.html?suite=${{ inputs.suite }} run: yarn dlx mocha-headless-chrome --timeout 3600000 -a no-sandbox -a disable-setuid-sandbox -f http://localhost:9001/mocha/test.html?suite=${{ inputs.suite }}
- name: Archive failed run logs - name: Archive failed run logs
if: ${{ failure() }} if: ${{ failure() }}
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v4
with: with:
name: self-hosted-failure-logs-${{ inputs.suite }} name: self-hosted-failure-logs-${{ inputs.suite }}
retention-days: 5 retention-days: 5
path: | path: |
logs/*.err logs/*.err
logs/*.log logs/*.log
Generated
+529 -653
View File
File diff suppressed because it is too large Load Diff
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.
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.

Some files were not shown because too many files have changed in this diff Show More