We have our deployment script with fabric, and it has a list of hosts:
env.hosts = ['services', 'w1zA', 'w1zB']
but we have 2 more servers that are on and off when there is more pressure.
So I want my hosts variable to be:
env.hosts = ['services', 'w1zA', 'w1zB', 'w2zA', 'w2zB']
but now when I run the script when the extra servers are off, the deployment fails because it can't connect to those servers.
How can I skip failures if server is off?
You can use env.skip_bad_hosts = True
option.
Here is documentation about it: http://docs.fabfile.org/en/latest/usage/env.html#skip-bad-hosts
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.