Create the following function object in fabfile.py
fabfile.py
env.hosts = ['127.0.0.1']
def local():
env.hosts = ['127.0.0.1']
def all():
env.hosts = ['aaa.example.com','bbb.example.com',...]
def deploy():
#processing
At the time of calling
call
% #Localhost only
% fab local deploy
%
% #Multiple hosts
% fab all deploy
Recommended Posts