Skip to content

Commit

Permalink
added "--wait-finish" for occ app_api:app:register (AppAPI 1.3+)
Browse files Browse the repository at this point in the history
Signed-off-by: Alexander Piskun <bigcat88@icloud.com>
  • Loading branch information
bigcat88 committed Nov 27, 2023
1 parent 93b0f73 commit cccb581
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion scripts/ci_register.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@
php occ app_api:daemon:register manual_install "Manual Install" manual-install 0 0 0
php occ app_api:app:register "$1" manual_install --json-info \
"{\"appid\":\"$1\",\"name\":\"$1\",\"daemon_config_name\":\"manual_install\",\"version\":\"$2\",\"secret\":\"$3\",\"host\":\"$4\",\"scopes\":{\"required\":[\"SYSTEM\", \"FILES\", \"FILES_SHARING\"],\"optional\":[\"USER_INFO\", \"USER_STATUS\", \"NOTIFICATIONS\", \"WEATHER_STATUS\", \"TALK\", \"TALK_BOT\", \"ACTIVITIES\", \"NOTES\"]},\"port\":$5,\"protocol\":\"http\",\"system_app\":1}" \
--force-scopes
--force-scopes --wait-finish
2 changes: 1 addition & 1 deletion scripts/dev_register.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ echo $! > /tmp/_install.pid
python3 tests/_install_wait.py "http://localhost:9009/heartbeat" "\"status\":\"ok\"" 15 0.5
docker exec "$1" sudo -u www-data php occ app_api:app:register nc_py_api manual_install --json-info \
"{\"appid\":\"nc_py_api\",\"name\":\"nc_py_api\",\"daemon_config_name\":\"manual_install\",\"version\":\"1.0.0\",\"secret\":\"12345\",\"host\":\"host.docker.internal\",\"scopes\":{\"required\":[\"SYSTEM\", \"FILES\", \"FILES_SHARING\"],\"optional\":[\"USER_INFO\", \"USER_STATUS\", \"NOTIFICATIONS\", \"WEATHER_STATUS\", \"TALK\", \"TALK_BOT\", \"ACTIVITIES\", \"NOTES\"]},\"port\":9009,\"protocol\":\"http\",\"system_app\":1}" \
--force-scopes
--force-scopes --wait-finish
cat /tmp/_install.pid
kill -15 "$(cat /tmp/_install.pid)"
echo "nc_py_api for $1 is ready to use"

0 comments on commit cccb581

Please sign in to comment.