-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Machine Add the possibility to force broker to always assign the same machine to a user #312
Machine Add the possibility to force broker to always assign the same machine to a user #312
Conversation
@@ -29,6 +29,8 @@ to avoid commiting those changes | |||
- machinesName (Defaults to 'Nanocloud Exec Server') default name for machines | |||
- plazaURI (Defaults to https://s3-eu-west-1.amazonaws.com/nanocloud/plaza/1.0.0/windows/amd64/plaza.exe) URL to download plaza from | |||
- plazaPort (Defaults to 9090) port to communicate with plaza | |||
- neverTerminateMachine (Defaults to false) if set to true, machines are | |||
never destroyed, users have always the same machine all times. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
users have always the same machine all times. -> users always keep the same machine at all time.
isActive: machine.isSessionActive(), | ||
config: ConfigService.get('neverTerminateMachine') | ||
}) | ||
.then((props) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should use object destructuring in this case: https://ponyfoo.com/articles/es6-destructuring-in-depth
3f10646
to
08a4aff
Compare
config: ConfigService.get('neverTerminateMachine') | ||
}) | ||
.then((props) => { | ||
var {isActive, config} = props; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
{isActive, config}
could and should be in the argument list.
e5079c5
to
c798571
Compare
Stop will not destroy the machine, she will just stop taking resources. Start on a stopped machine will rerun her, so she can be reused.
with the right attribute (start, stop).
Stop will not destroy the machine, she will just stop taking resources. Start on a stopped machine will rerun her, so she can be reused.
to a user. This option is available only in the config file.
So we let the startMachine function do it.
c798571
to
698d0dd
Compare
Add a configuration variable to set this option.
If set to true, no machines are terminated. If a machine expire, it is just stopped, and started again when the user want to use it.
Fixes #294