Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
82 changes: 47 additions & 35 deletions .github/workflows/floccus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ jobs:
matrix:
node-version: [20.x]
npm-version: [10.x]
server-version: ['32']
server-version: ['stable32', 'stable35', 'master']
floccus-branch: ['master', 'develop']
floccus-adapter:
- nextcloud-bookmarks
Expand All @@ -100,7 +100,7 @@ jobs:
browsers:
- firefox

name: ${{ matrix.browsers }} floccus@${{ matrix.floccus-branch }} ${{ matrix.floccus-adapter }}:${{ matrix.test-name}}
name: ${{ matrix.browsers }} floccus@${{ matrix.floccus-branch }} Nextcloud ${{ matrix.server-version }} ${{ matrix.floccus-adapter }}:${{ matrix.test-name}}

services:
hub:
Expand All @@ -116,29 +116,21 @@ jobs:
SE_EVENT_BUS_HOST: hub
SE_EVENT_BUS_PUBLISH_PORT: 4442
SE_EVENT_BUS_SUBSCRIBE_PORT: 4443
options: --shm-size="2g"
options: --shm-size="2g" --add-host=nextcloud:host-gateway
chrome:
image: selenium/node-chrome:4.11.0-20230801
env:
SE_EVENT_BUS_HOST: hub
SE_EVENT_BUS_PUBLISH_PORT: 4442
SE_EVENT_BUS_SUBSCRIBE_PORT: 4443
options: --shm-size="2g"
nextcloud:
image: nextcloud:${{ matrix.server-version }}
env:
NEXTCLOUD_ADMIN_USER: admin
NEXTCLOUD_ADMIN_PASSWORD: admin
MYSQL_DATABASE: nextcloud
MYSQL_USER: root
MYSQL_PASSWORD: ${{env.MYSQL_PASSWORD}}
MYSQL_HOST: mysql
NEXTCLOUD_TRUSTED_DOMAINS: nextcloud
options: --name nextcloud
options: --shm-size="2g" --add-host=nextcloud:host-gateway
mysql:
image: mariadb:10.5 # see https://github.com/nextcloud/docker/issues/1536
image: mariadb:10.11
ports:
- 4445:3306/tcp
env:
MYSQL_ROOT_PASSWORD: ${{env.MYSQL_PASSWORD}}
options: --health-cmd="mysqladmin ping" --health-interval 5s --health-timeout 2s --health-retries 10

steps:

Expand All @@ -157,36 +149,51 @@ jobs:
key: floccus-context-${{matrix.floccus-branch}}-${{ github.run_id }}
path: ./

- name: Checkout Nextcloud source
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
repository: nextcloud/server
ref: ${{ matrix.server-version }}
submodules: true
path: server

- name: Set up PHP
uses: shivammathur/setup-php@f3e473d116dcccaddc5834248c87452386958240 # 2.37.2
with:
php-version: '8.3'
extensions: curl, dom, fileinfo, gd, intl, mbstring, pdo_mysql, zip, apcu
ini-values: apc.enable_cli=1
coverage: none

- name: Checkout bookmarks app
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
path: ${{ env.APP_NAME }}
path: server/apps/${{ env.APP_NAME }}

- name: Install bookmarks app
shell: bash
working-directory: server/apps/${{ env.APP_NAME }}
run: |
pwd
cd ${{ env.APP_NAME }}
composer install --ignore-platform-req=php --no-dev
composer remove nextcloud/ocp --dev --no-update
composer install --no-dev

- name: Enable bookmarks app
- name: Install Nextcloud and enable bookmarks
working-directory: server
shell: bash
run: |
docker cp ${{env.APP_NAME}} nextcloud:/var/www/html/apps/
NEXT_WAIT_TIME=0
until [ $NEXT_WAIT_TIME -eq 25 ] || docker exec --user www-data nextcloud php occ app:enable ${{ env.APP_NAME }}; do
sleep $(( NEXT_WAIT_TIME++ ))
done
[ $NEXT_WAIT_TIME -lt 25 ]

- name: Enable APCu
php occ maintenance:install --database=mysql --database-name=nextcloud --database-host=127.0.0.1 --database-port=4445 --database-user=root --database-pass="$MYSQL_PASSWORD" --admin-user=admin --admin-pass=admin
php occ config:system:set trusted_domains 1 --value=nextcloud
php occ app:enable ${{ env.APP_NAME }}
php occ config:system:set --value '\OC\Memcache\APCu' memcache.local
php occ status

- name: Serve Nextcloud to the browser containers
working-directory: server
run: |
NEXT_WAIT_TIME=0
until [ $NEXT_WAIT_TIME -eq 25 ] || docker exec --user www-data nextcloud php occ config:system:set --value "\\OC\\Memcache\\APCu" memcache.local; do
sleep $(( NEXT_WAIT_TIME++ ))
done
[ $NEXT_WAIT_TIME -lt 25 ]
echo '127.0.0.1 nextcloud' | sudo tee -a /etc/hosts
sudo env PHP_CLI_SERVER_WORKERS=4 "$(command -v php)" -S 0.0.0.0:80 > "$RUNNER_TEMP/nextcloud-http.log" 2>&1 &
curl --fail --retry 20 --retry-connrefused --retry-delay 1 http://nextcloud/status.php

- name: Wait for Selenium
run: |
Expand All @@ -207,6 +214,11 @@ jobs:
run: |
npm run test

- name: Print Nextcloud logs
if: always()
run: |
cat server/data/nextcloud.log "$RUNNER_TEMP/nextcloud-http.log" 2>/dev/null || true

summary:
runs-on: ubuntu-latest-low
needs: [ init, selenium ]
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/phpunit-mariadb.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ jobs:
matrix:
php-versions: ${{ fromJson(needs.matrix.outputs.php-version) }}
server-versions: ${{ fromJson(needs.matrix.outputs.server-max) }}
mariadb-versions: ['10.6', '11.4']
mariadb-versions: ['10.11', '11.4']

name: MariaDB ${{ matrix.mariadb-versions }} PHP ${{ matrix.php-versions }} Nextcloud ${{ matrix.server-versions }}

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/phpunit-sqlite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ jobs:
run: |
mkdir data
./occ maintenance:install --verbose --database=sqlite --database-name=nextcloud --database-host=127.0.0.1 --database-port=$DB_PORT --database-user=root --database-pass=rootpassword --admin-user admin --admin-pass admin
./occ app:enable --force ${{ env.APP_NAME }}
./occ app:enable ${{ env.APP_NAME }}

- name: Check PHPUnit script is defined
id: check_phpunit
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/repair.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ jobs:

services:
mysql:
image: mariadb:10.5
image: mariadb:10.11
ports:
- 4444:3306/tcp
env:
Expand Down
26 changes: 25 additions & 1 deletion .github/workflows/upgrade.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,30 @@ jobs:
server-versions: 'stable32'
php-versions: '8.1'
prev-version: 'stable'
- databases: 'sqlite'
server-versions: 'stable35'
php-versions: '8.3'
prev-version: 'v16.2.6'
- databases: 'mysql'
server-versions: 'stable35'
php-versions: '8.3'
prev-version: 'v16.2.6'
- databases: 'pgsql'
server-versions: 'stable35'
php-versions: '8.3'
prev-version: 'v16.2.6'
- databases: 'sqlite'
server-versions: 'master'
php-versions: '8.3'
prev-version: 'v16.2.6'
- databases: 'mysql'
server-versions: 'master'
php-versions: '8.3'
prev-version: 'v16.2.6'
- databases: 'pgsql'
server-versions: 'master'
php-versions: '8.3'
prev-version: 'v16.2.6'

name: Update from ${{ matrix.prev-version }} on ${{ matrix.databases }}-${{ matrix.server-versions }}

Expand All @@ -46,7 +70,7 @@ jobs:

services:
mysql:
image: mariadb:10.5
image: mariadb:10.11
ports:
- 4444:3306/tcp
env:
Expand Down
2 changes: 1 addition & 1 deletion appinfo/info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ Requirements:
<database>pgsql</database>
<lib>intl</lib>
<lib>mbstring</lib>
<nextcloud min-version="32" max-version="34" />
<nextcloud min-version="32" max-version="36" />
</dependencies>
<background-jobs>
<job>OCA\Bookmarks\BackgroundJobs\CrawlJob</job>
Expand Down
2 changes: 1 addition & 1 deletion lib/Migration/Version003000009Date20200505094721.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public function changeSchema(IOutput $output, Closure $schemaClosure, array $opt
/** @var ISchemaWrapper $schema */
$schema = $schemaClosure();
$table = $schema->getTable('bookmarks_tree');
$table->changeColumn('index', [
$table->modifyColumn('index', [
'type' => Type::getType('bigint'),
'unsigned' => true,
]);
Expand Down