From 092f0cfcaf6ef733cf6de579f4997b59ebcf6802 Mon Sep 17 00:00:00 2001 From: Steven Nguyen Date: Fri, 2 Jun 2023 14:22:28 -0700 Subject: [PATCH 1/7] Fix the routing for the default OAuth2 pages --- app/controllers/web/console.php | 3 ++- tests/e2e/General/HTTPTest.php | 11 +++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/app/controllers/web/console.php b/app/controllers/web/console.php index fa4f76a9d0..59aad607c1 100644 --- a/app/controllers/web/console.php +++ b/app/controllers/web/console.php @@ -5,10 +5,11 @@ use Utopia\App; App::get('/console/*') ->alias('/') + ->alias('auth/*') ->alias('/invite') ->alias('/login') ->alias('/recover') - ->alias('/register') + ->alias('/register/*') ->groups(['web']) ->label('permission', 'public') ->label('scope', 'home') diff --git a/tests/e2e/General/HTTPTest.php b/tests/e2e/General/HTTPTest.php index 608afdccd3..087b984f9d 100644 --- a/tests/e2e/General/HTTPTest.php +++ b/tests/e2e/General/HTTPTest.php @@ -160,4 +160,15 @@ class HTTPTest extends Scope $this->assertIsString($body['server-ruby']); $this->assertIsString($body['console-cli']); } + + public function testDefaultOAuth2() + { + $response = $this->client->call(Client::METHOD_GET, '/auth/oauth2/success', $this->getHeaders()); + + $this->assertEquals(200, $response['headers']['status-code']); + + $response = $this->client->call(Client::METHOD_GET, '/auth/oauth2/failure', $this->getHeaders()); + + $this->assertEquals(200, $response['headers']['status-code']); + } } From 8b01c61de3fbfe058a8da36f280c7e81041303a5 Mon Sep 17 00:00:00 2001 From: Christy Jacob Date: Sat, 3 Jun 2023 19:33:51 +0530 Subject: [PATCH 2/7] chore: update utopia-php/framework --- .github/workflows/build-cloud.yml | 53 +++++++++++++++++++++++++++++++ app/console | 2 +- composer.lock | 34 +++++++++++--------- 3 files changed, 73 insertions(+), 16 deletions(-) create mode 100644 .github/workflows/build-cloud.yml diff --git a/.github/workflows/build-cloud.yml b/.github/workflows/build-cloud.yml new file mode 100644 index 0000000000..f4158a3180 --- /dev/null +++ b/.github/workflows/build-cloud.yml @@ -0,0 +1,53 @@ +name: "Release" + +on: + release: + types: [published] + +jobs: + tests: + name: Release + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + with: + # We must fetch at least the immediate parents so that if this is + # a pull request then we can checkout the head. + fetch-depth: 2 + # Fetch submodules + submodules: recursive + + - name: Set up QEMU + uses: docker/setup-qemu-action@v2 + + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + + - name: Login to Docker Hub + uses: docker/login-action@v2 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + + - name: Extract metadata (tags, labels) for Docker + id: meta + uses: docker/metadata-action@v4 + with: + images: appwrite/appwrite + tags: | + type=semver,pattern={{major}}.{{minor}}.{{patch}} + type=semver,pattern={{major}}.{{minor}} + type=semver,pattern={{major}} + + - name: Build and push + uses: docker/build-push-action@v4 + with: + context: . + platforms: linux/amd64,linux/arm64 + build-args: | + VERSION=${{ steps.meta.outputs.version }} + push: true + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} \ No newline at end of file diff --git a/app/console b/app/console index 9174d8f8cb..b981302dee 160000 --- a/app/console +++ b/app/console @@ -1 +1 @@ -Subproject commit 9174d8f8cb584744dd7a53f69d324f490ee82ee3 +Subproject commit b981302dee30eab33e155af79f0088822b29a2b6 diff --git a/composer.lock b/composer.lock index 99273a9386..f9afb562f7 100644 --- a/composer.lock +++ b/composer.lock @@ -2218,16 +2218,16 @@ }, { "name": "utopia-php/framework", - "version": "0.28.3", + "version": "0.26.3", "source": { "type": "git", "url": "https://github.com/utopia-php/framework.git", - "reference": "9b6171eeb99a2f0a550f51526d583e012dfac4e9" + "reference": "7a18a2b0d6c8dba878c926b73650fd2c4eeaa70d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/framework/zipball/9b6171eeb99a2f0a550f51526d583e012dfac4e9", - "reference": "9b6171eeb99a2f0a550f51526d583e012dfac4e9", + "url": "https://api.github.com/repos/utopia-php/framework/zipball/7a18a2b0d6c8dba878c926b73650fd2c4eeaa70d", + "reference": "7a18a2b0d6c8dba878c926b73650fd2c4eeaa70d", "shasum": "" }, "require": { @@ -2257,9 +2257,9 @@ ], "support": { "issues": "https://github.com/utopia-php/framework/issues", - "source": "https://github.com/utopia-php/framework/tree/0.28.3" + "source": "https://github.com/utopia-php/framework/tree/0.26.3" }, - "time": "2023-06-02T10:57:17+00:00" + "time": "2023-06-03T14:01:15+00:00" }, { "name": "utopia-php/image", @@ -3083,25 +3083,29 @@ }, { "name": "doctrine/deprecations", - "version": "v1.1.0", + "version": "v1.1.1", "source": { "type": "git", "url": "https://github.com/doctrine/deprecations.git", - "reference": "8cffffb2218e01f3b370bf763e00e81697725259" + "reference": "612a3ee5ab0d5dd97b7cf3874a6efe24325efac3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/deprecations/zipball/8cffffb2218e01f3b370bf763e00e81697725259", - "reference": "8cffffb2218e01f3b370bf763e00e81697725259", + "url": "https://api.github.com/repos/doctrine/deprecations/zipball/612a3ee5ab0d5dd97b7cf3874a6efe24325efac3", + "reference": "612a3ee5ab0d5dd97b7cf3874a6efe24325efac3", "shasum": "" }, "require": { - "php": "^7.1|^8.0" + "php": "^7.1 || ^8.0" }, "require-dev": { "doctrine/coding-standard": "^9", - "phpunit/phpunit": "^7.5|^8.5|^9.5", - "psr/log": "^1|^2|^3" + "phpstan/phpstan": "1.4.10 || 1.10.15", + "phpstan/phpstan-phpunit": "^1.0", + "phpunit/phpunit": "^7.5 || ^8.5 || ^9.5", + "psalm/plugin-phpunit": "0.18.4", + "psr/log": "^1 || ^2 || ^3", + "vimeo/psalm": "4.30.0 || 5.12.0" }, "suggest": { "psr/log": "Allows logging deprecations via PSR-3 logger implementation" @@ -3120,9 +3124,9 @@ "homepage": "https://www.doctrine-project.org/", "support": { "issues": "https://github.com/doctrine/deprecations/issues", - "source": "https://github.com/doctrine/deprecations/tree/v1.1.0" + "source": "https://github.com/doctrine/deprecations/tree/v1.1.1" }, - "time": "2023-05-29T18:55:17+00:00" + "time": "2023-06-03T09:27:29+00:00" }, { "name": "doctrine/instantiator", From 9dee8346370fc758198e9d287bdd87315667c519 Mon Sep 17 00:00:00 2001 From: Christy Jacob Date: Sat, 3 Jun 2023 19:34:49 +0530 Subject: [PATCH 3/7] chore: remove unrelated files --- .github/workflows/build-cloud.yml | 53 ------------------------------- 1 file changed, 53 deletions(-) delete mode 100644 .github/workflows/build-cloud.yml diff --git a/.github/workflows/build-cloud.yml b/.github/workflows/build-cloud.yml deleted file mode 100644 index f4158a3180..0000000000 --- a/.github/workflows/build-cloud.yml +++ /dev/null @@ -1,53 +0,0 @@ -name: "Release" - -on: - release: - types: [published] - -jobs: - tests: - name: Release - runs-on: ubuntu-latest - - steps: - - name: Checkout repository - uses: actions/checkout@v3 - with: - # We must fetch at least the immediate parents so that if this is - # a pull request then we can checkout the head. - fetch-depth: 2 - # Fetch submodules - submodules: recursive - - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v2 - - - name: Login to Docker Hub - uses: docker/login-action@v2 - with: - username: ${{ secrets.DOCKERHUB_USERNAME }} - password: ${{ secrets.DOCKERHUB_TOKEN }} - - - name: Extract metadata (tags, labels) for Docker - id: meta - uses: docker/metadata-action@v4 - with: - images: appwrite/appwrite - tags: | - type=semver,pattern={{major}}.{{minor}}.{{patch}} - type=semver,pattern={{major}}.{{minor}} - type=semver,pattern={{major}} - - - name: Build and push - uses: docker/build-push-action@v4 - with: - context: . - platforms: linux/amd64,linux/arm64 - build-args: | - VERSION=${{ steps.meta.outputs.version }} - push: true - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} \ No newline at end of file From 329b6b93bfe3ce1d6356ccde06c824e97361b53e Mon Sep 17 00:00:00 2001 From: Christy Jacob Date: Sat, 3 Jun 2023 20:11:01 +0530 Subject: [PATCH 4/7] chore: update changelog --- CHANGES.md | 9 +++++++++ README-CN.md | 6 +++--- README.md | 6 +++--- app/init.php | 4 ++-- src/Appwrite/Migration/Migration.php | 1 + 5 files changed, 18 insertions(+), 8 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index d1fe64df33..990f19db15 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,3 +1,12 @@ +# Version 1.3.7 + +- Fix the routing for the default OAuth2 pages [#5640](https://github.com/appwrite/appwrite/pull/5640) [#5648](https://github.com/appwrite/appwrite/pull/5648) +- Add support for trailing slashes in Routes and URLs [#5647](https://github.com/appwrite/appwrite/pull/5647) [#5648](https://github.com/appwrite/appwrite/pull/5648) +## Bugs + +- Fix Console deep linking to result in a 404 [#5632](https://github.com/appwrite/appwrite/pull/5632) +- Fix ACME HTTP Challenge [#5632](https://github.com/appwrite/appwrite/pull/5632) + # Version 1.3.6 ## Bugs diff --git a/README-CN.md b/README-CN.md index bf0a73adaf..d3f52058b5 100644 --- a/README-CN.md +++ b/README-CN.md @@ -66,7 +66,7 @@ docker run -it --rm \ --volume /var/run/docker.sock:/var/run/docker.sock \ --volume "$(pwd)"/appwrite:/usr/src/code/appwrite:rw \ --entrypoint="install" \ - appwrite/appwrite:1.3.6 + appwrite/appwrite:1.3.7 ``` ### Windows @@ -78,7 +78,7 @@ docker run -it --rm ^ --volume //var/run/docker.sock:/var/run/docker.sock ^ --volume "%cd%"/appwrite:/usr/src/code/appwrite:rw ^ --entrypoint="install" ^ - appwrite/appwrite:1.3.6 + appwrite/appwrite:1.3.7 ``` #### PowerShell @@ -88,7 +88,7 @@ docker run -it --rm ` --volume /var/run/docker.sock:/var/run/docker.sock ` --volume ${pwd}/appwrite:/usr/src/code/appwrite:rw ` --entrypoint="install" ` - appwrite/appwrite:1.3.6 + appwrite/appwrite:1.3.7 ``` 运行后,可以在浏览器上访问 http://localhost 找到 Appwrite 控制台。在非 Linux 的本机主机上完成安装后,服务器可能需要几分钟才能启动。 diff --git a/README.md b/README.md index 45caeaa564..b8fffd110a 100644 --- a/README.md +++ b/README.md @@ -75,7 +75,7 @@ docker run -it --rm \ --volume /var/run/docker.sock:/var/run/docker.sock \ --volume "$(pwd)"/appwrite:/usr/src/code/appwrite:rw \ --entrypoint="install" \ - appwrite/appwrite:1.3.6 + appwrite/appwrite:1.3.7 ``` ### Windows @@ -87,7 +87,7 @@ docker run -it --rm ^ --volume //var/run/docker.sock:/var/run/docker.sock ^ --volume "%cd%"/appwrite:/usr/src/code/appwrite:rw ^ --entrypoint="install" ^ - appwrite/appwrite:1.3.6 + appwrite/appwrite:1.3.7 ``` #### PowerShell @@ -97,7 +97,7 @@ docker run -it --rm ` --volume /var/run/docker.sock:/var/run/docker.sock ` --volume ${pwd}/appwrite:/usr/src/code/appwrite:rw ` --entrypoint="install" ` - appwrite/appwrite:1.3.6 + appwrite/appwrite:1.3.7 ``` Once the Docker installation is complete, go to http://localhost to access the Appwrite console from your browser. Please note that on non-Linux native hosts, the server might take a few minutes to start after completing the installation. diff --git a/app/init.php b/app/init.php index 5eb7f67aa3..0b6efe52c0 100644 --- a/app/init.php +++ b/app/init.php @@ -100,8 +100,8 @@ const APP_LIMIT_WRITE_RATE_PERIOD_DEFAULT = 60; // Default maximum write rate pe const APP_LIMIT_LIST_DEFAULT = 25; // Default maximum number of items to return in list API calls const APP_KEY_ACCCESS = 24 * 60 * 60; // 24 hours const APP_CACHE_UPDATE = 24 * 60 * 60; // 24 hours -const APP_CACHE_BUSTER = 505; -const APP_VERSION_STABLE = '1.3.6'; +const APP_CACHE_BUSTER = 506; +const APP_VERSION_STABLE = '1.3.7'; const APP_DATABASE_ATTRIBUTE_EMAIL = 'email'; const APP_DATABASE_ATTRIBUTE_ENUM = 'enum'; const APP_DATABASE_ATTRIBUTE_IP = 'ip'; diff --git a/src/Appwrite/Migration/Migration.php b/src/Appwrite/Migration/Migration.php index b205fdc55a..7a1f3cad24 100644 --- a/src/Appwrite/Migration/Migration.php +++ b/src/Appwrite/Migration/Migration.php @@ -62,6 +62,7 @@ abstract class Migration '1.3.4' => 'V18', '1.3.5' => 'V18', '1.3.6' => 'V18', + '1.3.7' => 'V18', ]; /** From 9dcf164b2fbae7a23b02e46fe6f5b9f3bd776cdb Mon Sep 17 00:00:00 2001 From: Christy Jacob Date: Sat, 3 Jun 2023 20:14:11 +0530 Subject: [PATCH 5/7] chore: update composer --- composer.lock | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/composer.lock b/composer.lock index f9afb562f7..a261c416e7 100644 --- a/composer.lock +++ b/composer.lock @@ -2218,16 +2218,16 @@ }, { "name": "utopia-php/framework", - "version": "0.26.3", + "version": "0.28.4", "source": { "type": "git", "url": "https://github.com/utopia-php/framework.git", - "reference": "7a18a2b0d6c8dba878c926b73650fd2c4eeaa70d" + "reference": "98c5469efe195aeecc63745dbf8e2f357f8cedac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/framework/zipball/7a18a2b0d6c8dba878c926b73650fd2c4eeaa70d", - "reference": "7a18a2b0d6c8dba878c926b73650fd2c4eeaa70d", + "url": "https://api.github.com/repos/utopia-php/framework/zipball/98c5469efe195aeecc63745dbf8e2f357f8cedac", + "reference": "98c5469efe195aeecc63745dbf8e2f357f8cedac", "shasum": "" }, "require": { @@ -2257,9 +2257,9 @@ ], "support": { "issues": "https://github.com/utopia-php/framework/issues", - "source": "https://github.com/utopia-php/framework/tree/0.26.3" + "source": "https://github.com/utopia-php/framework/tree/0.28.4" }, - "time": "2023-06-03T14:01:15+00:00" + "time": "2023-06-03T14:09:22+00:00" }, { "name": "utopia-php/image", From a68f0826e78b2c543177f50009b2112bb5a5a0f1 Mon Sep 17 00:00:00 2001 From: Christy Jacob Date: Sat, 3 Jun 2023 20:14:44 +0530 Subject: [PATCH 6/7] chore: update changelog --- CHANGES.md | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 990f19db15..abe1dacac1 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,11 +1,8 @@ # Version 1.3.7 +## Bugs - Fix the routing for the default OAuth2 pages [#5640](https://github.com/appwrite/appwrite/pull/5640) [#5648](https://github.com/appwrite/appwrite/pull/5648) - Add support for trailing slashes in Routes and URLs [#5647](https://github.com/appwrite/appwrite/pull/5647) [#5648](https://github.com/appwrite/appwrite/pull/5648) -## Bugs - -- Fix Console deep linking to result in a 404 [#5632](https://github.com/appwrite/appwrite/pull/5632) -- Fix ACME HTTP Challenge [#5632](https://github.com/appwrite/appwrite/pull/5632) # Version 1.3.6 From 596998000b76407aaaced89a5ca72341839b7039 Mon Sep 17 00:00:00 2001 From: Christy Jacob Date: Sat, 3 Jun 2023 20:15:40 +0530 Subject: [PATCH 7/7] chore: update console --- app/console | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/console b/app/console index b981302dee..9174d8f8cb 160000 --- a/app/console +++ b/app/console @@ -1 +1 @@ -Subproject commit b981302dee30eab33e155af79f0088822b29a2b6 +Subproject commit 9174d8f8cb584744dd7a53f69d324f490ee82ee3