start.sh 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. #!/usr/bin/env bash
  2. set -e
  3. # Run a complete joystream development network on your machine using docker
  4. INIT_CHAIN_SCENARIO=${INIT_CHAIN_SCENARIO:=setup-new-chain}
  5. if [ "${PERSIST}" == true ]
  6. then
  7. echo "Services startup up.."
  8. else
  9. # Clean start!
  10. docker-compose down -v
  11. function down()
  12. {
  13. # Stop containers and clear volumes
  14. docker-compose down -v
  15. }
  16. trap down EXIT
  17. fi
  18. ## Run a local development chain
  19. docker-compose up -d joystream-node
  20. ## Init the chain with some state
  21. export SKIP_MOCK_CONTENT=true
  22. ./tests/network-tests/run-test-scenario.sh ${INIT_CHAIN_SCENARIO}
  23. ## Set sudo as the membership screening authority
  24. yarn workspace api-scripts set-sudo-as-screening-auth
  25. ## Member faucet
  26. docker-compose up -d faucet
  27. ## Storage Infrastructure Configuration
  28. ./storage-playground-config.sh
  29. ## Query Node Infrastructure
  30. ./query-node/start.sh
  31. ## Storage Infrastructure Nodes
  32. docker-compose up -d colossus-1
  33. docker-compose up -d distributor-1
  34. ## Pioneer UI
  35. docker-compose up -d pioneer
  36. ## Orion
  37. docker-compose up -d orion
  38. if [ "${PERSIST}" == true ]
  39. then
  40. echo "All services started in the background"
  41. else
  42. echo "use Ctrl+C to shutdown the development network."
  43. while true; do
  44. read
  45. done
  46. fi