Simplify camunda account-portal local dev setup (#13482)

This commit is contained in:
melohagan 2024-04-15 14:37:12 +01:00 committed by GitHub
parent 0a483a7869
commit 8b9d07fed6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 32 additions and 0 deletions

View File

@ -56,6 +56,7 @@
"dev:noserver": "yarn run kill-builder && lerna run --stream dev:stack:up --ignore @budibase/account-portal-server && lerna run --stream dev --ignore @budibase/backend-core --ignore @budibase/server --ignore @budibase/worker --ignore=@budibase/account-portal-ui --ignore @budibase/account-portal-server",
"dev:server": "yarn run kill-server && lerna run --stream dev --scope @budibase/worker --scope @budibase/server",
"dev:accountportal": "yarn kill-accountportal && lerna run dev --stream --scope @budibase/account-portal-ui --scope @budibase/account-portal-server",
"dev:camunda": "./scripts/deploy-camunda.sh",
"dev:all": "yarn run kill-all && lerna run --stream dev",
"dev:built": "yarn run kill-all && cd packages/server && yarn dev:stack:up && cd ../../ && lerna run --stream dev:built",
"dev:docker": "yarn build --scope @budibase/server --scope @budibase/worker && docker-compose -f hosting/docker-compose.build.yaml -f hosting/docker-compose.dev.yaml --env-file hosting/.env up --build --scale proxy-service=0",

31
scripts/deploy-camunda.sh Executable file
View File

@ -0,0 +1,31 @@
#!/bin/bash
yarn global add zbctl
export ZEEBE_ADDRESS='localhost:26500'
cd ../budibase-bpm
is_camunda_ready() {
if (zbctl --insecure status 2>/dev/null) | grep -q 'Healthy'; then
return 1
else
return 0
fi
}
docker-compose up -d
echo "waiting for Camunda to be ready..."
while is_camunda_ready -eq 0; do sleep 1; done
cd src/main/resources/models
echo "deploy processes..."
zbctl deploy resource offboarding.bpmn --insecure
zbctl deploy resource onboarding.bpmn --insecure
cd ../../../../../budibase/packages/account-portal/packages/server
yarn worker:run & cd ../../../.. && yarn dev:accountportal