Skip to content

SE-2868 Prevent users from spawning many appservers in parallel from the new UI

Created by: mavidser

This PR disables the new OCIM console for staff users

JIRA tickets: SE-2868

Testing instructions:

  • Checkout this branch.
  • Add DEPLOYMENT_START_DELAY=600 to your .env (~10 mins is also my recommendation for prod)
  • Start the webserver and huey workers make run.dev
  • Start the ocim console - cd frontend && ./scripts/build-api-client.sh && npm install && npm start
  • On the ocim console, create a new user, or login with an existing one.
  • Do a couple of deployments in 10 mins by doing changes on the instances and clicking 'Deploy' a few times.
  • Observe huey worker logs - only the last deployment should have started, and the rest should have no-oped by logging 'cancelled'.
  • Start a deployment after 10 mins (when an appserver has started provisioning). The provisioning should get cancelled, and a new deployment should be scheduled.
  • Verify instances on OVH too to see that cancelled appservers get deleted when new ones are provisioned.
  • Run all tests - make test

Reviewers

Merge request reports