Update 'src/containerspawner/state.py'
continuous-integration/drone/push Build is failing Details

This commit is contained in:
Jack Hadrill 2022-08-27 19:39:24 +00:00
parent 30c166e77b
commit 3fbf8cd97c
1 changed files with 7 additions and 0 deletions

View File

@ -44,11 +44,15 @@ class StateManager:
name=container_name,
network=CONTAINER_NETWORK,
volumes={container_name: {"bind": CONTAINER_PERSIST}},
restart_policy={"Name": "always", "MaximumRetryCount": 5}
detach=True,
auto_remove=True
)
# Wait for container to start.
while container.status != "running":
time.sleep(1)
time.sleep(3)
# Disable auth.
@ -56,3 +60,6 @@ class StateManager:
# Install extensions.
container.exec_run("code-server --install-extension ms-python.python")
# Restart container.
container.restart()