Avoid cleaning up API tokens for Spawners that will resume

in which case the previous API token should be left alone.
This commit is contained in:
Min RK
2016-12-19 10:50:25 +01:00
parent fcf32c7e50
commit 72ab8f99ec
2 changed files with 18 additions and 3 deletions

View File

@@ -52,6 +52,14 @@ class Spawner(LoggingConfigurable):
authenticator = Any()
api_token = Unicode()
will_resume = Bool(False,
help="""Whether the Spawner will resume on next start
If a Spawner will resume instead of starting anew (e.g. resuming a Docker container),
API tokens in use when the Spawner stops will not be deleted.
"""
)
ip = Unicode('127.0.0.1',
help="""
The IP address (or hostname) the single-user server should listen on.