From 36cc6d8621ebe093a9d6bfc44eefb94ed8269b3a Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Thu, 17 Nov 2022 14:38:49 +0100 Subject: [PATCH 1/5] chore: prepare 1.1.1 release --- README-CN.md | 6 +++--- README.md | 6 +++--- app/init.php | 2 +- src/Appwrite/Migration/Migration.php | 1 + 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/README-CN.md b/README-CN.md index 3dc0f6ff1..4f8156f2c 100644 --- a/README-CN.md +++ b/README-CN.md @@ -64,7 +64,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.1.0 + appwrite/appwrite:1.1.1 ``` ### Windows @@ -76,7 +76,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.1.0 + appwrite/appwrite:1.1.1 ``` #### PowerShell @@ -86,7 +86,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.1.0 + appwrite/appwrite:1.1.1 ``` 运行后,可以在浏览器上访问 http://localhost 找到 Appwrite 控制台。在非 Linux 的本机主机上完成安装后,服务器可能需要几分钟才能启动。 diff --git a/README.md b/README.md index 28b1ae6d7..694259711 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.1.0 + appwrite/appwrite:1.1.1 ``` ### 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.1.0 + appwrite/appwrite:1.1.1 ``` #### 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.1.0 + appwrite/appwrite:1.1.1 ``` Once the Docker installation completes, 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 installation completes. diff --git a/app/init.php b/app/init.php index c9a6097ab..3d24ef81d 100644 --- a/app/init.php +++ b/app/init.php @@ -95,7 +95,7 @@ const APP_LIMIT_WRITE_RATE_PERIOD_DEFAULT = 60; // Default maximum write rate pe const APP_KEY_ACCCESS = 24 * 60 * 60; // 24 hours const APP_CACHE_UPDATE = 24 * 60 * 60; // 24 hours const APP_CACHE_BUSTER = 501; -const APP_VERSION_STABLE = '1.1.0'; +const APP_VERSION_STABLE = '1.1.1'; 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 9c6b03391..6c293723e 100644 --- a/src/Appwrite/Migration/Migration.php +++ b/src/Appwrite/Migration/Migration.php @@ -46,6 +46,7 @@ abstract class Migration '1.0.1' => 'V15', '1.0.3' => 'V15', '1.1.0' => 'V16', + '1.1.1' => 'V16', ]; /** From 727c3839d608ce564fdaaa6132b97ed66035104d Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Thu, 17 Nov 2022 14:52:44 +0100 Subject: [PATCH 2/5] feat: upgrade console to 2.0.1 --- .gitmodules | 2 +- app/console | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitmodules b/.gitmodules index dc04bee3c..e9f13bb1a 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,4 +1,4 @@ [submodule "app/console"] path = app/console url = https://github.com/appwrite/console - branch = 2.0.0 + branch = 2.0.1 diff --git a/app/console b/app/console index de73c020a..f89584bdd 160000 --- a/app/console +++ b/app/console @@ -1 +1 @@ -Subproject commit de73c020a7798e580c48197816124ca4783e115b +Subproject commit f89584bdd4ba3de07fb54cecbc275b131e23a4fb From d1eae375773c830e5d90bf47381faa687e24bdca Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Thu, 17 Nov 2022 14:57:27 +0100 Subject: [PATCH 3/5] fix: make migration for oauth providers non-destructive --- src/Appwrite/Migration/Version/V16.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Appwrite/Migration/Version/V16.php b/src/Appwrite/Migration/Version/V16.php index 070b8e7d9..e86561e42 100644 --- a/src/Appwrite/Migration/Version/V16.php +++ b/src/Appwrite/Migration/Version/V16.php @@ -130,6 +130,10 @@ class V16 extends Migration } if (($authProviders[$provider . 'Appid'] ?? false) && ($authProviders[$provider . 'Secret'] ?? false)) { + if (array_key_exists($provider . 'Enabled', $authProviders)) { + continue; + } + $authProviders[$provider . 'Enabled'] = true; } } From bba9284c3ebaad1b78addb33f68cbb2ea83c4cb3 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Thu, 17 Nov 2022 14:58:16 +0100 Subject: [PATCH 4/5] chore: add comments to v16 migration --- src/Appwrite/Migration/Version/V16.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Appwrite/Migration/Version/V16.php b/src/Appwrite/Migration/Version/V16.php index e86561e42..80f43d7d4 100644 --- a/src/Appwrite/Migration/Version/V16.php +++ b/src/Appwrite/Migration/Version/V16.php @@ -121,7 +121,9 @@ class V16 extends Migration 'duration' => Auth::TOKEN_EXPIRATION_LOGIN_LONG ])); - + /** + * Enable OAuth providers with data + */ $authProviders = $document->getAttribute('authProviders', []); foreach (Config::getParam('providers') as $provider => $value) { From dd34dfce22a77c7723aa546202ceb3eb2f6330c1 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Thu, 17 Nov 2022 15:33:46 +0100 Subject: [PATCH 5/5] fix: migration for oauthproviders --- src/Appwrite/Migration/Version/V16.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Appwrite/Migration/Version/V16.php b/src/Appwrite/Migration/Version/V16.php index 80f43d7d4..1d56b246d 100644 --- a/src/Appwrite/Migration/Version/V16.php +++ b/src/Appwrite/Migration/Version/V16.php @@ -140,6 +140,8 @@ class V16 extends Migration } } + $document->setAttribute('authProviders', $authProviders); + break; }