Module Expr Str Import alias Import alias Import alias Import alias Import alias Import alias Import alias Import alias FunctionDef arguments args defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore SubscriptLoad NameLoad Index Str Assign NameStore Call AttributeLoad NameLoad attr Str If CompareIsNot NameLoad NameLoad body Assign NameStore Call NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr keyword SubscriptLoad NameLoad Index Str keyword Call NameLoad SubscriptLoad NameLoad Index Str keyword Call NameLoad SubscriptLoad NameLoad Index Str keyword NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Call NameLoad Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Str NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad NameLoad If CompareEq NameLoad Str body Expr Call AttributeLoad NameLoad attr NameLoad Str NameLoad orelse If CompareEq NameLoad Str body Expr Call AttributeLoad NameLoad attr NameLoad Str NameLoad orelse If CompareEq NameLoad Str body Expr Call AttributeLoad NameLoad attr NameLoad Str NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Dict Str NameLoad Assign NameStore ListLoad For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore SubscriptLoad NameLoad Index NameLoad Expr Call AttributeLoad NameLoad attr Str Str If CompareIn Str NameLoad body Assign NameStore SubscriptLoad NameLoad Index Str Assign NameStore Call AttributeLoad Str attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign SubscriptStore NameLoad Index Str NameLoad orelse Assign NameStore Call AttributeLoad Str attr SubscriptLoad NameLoad Index Str NameLoad Assign SubscriptStore NameLoad Index Str NameLoad Assign NameStore Call AttributeLoad Str attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign NameStore Call AttributeLoad Str attr SubscriptLoad NameLoad Index Str NameLoad Assign SubscriptStore NameLoad Index Str NameLoad Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore SubscriptLoad SubscriptLoad NameLoad Index Str Index NameLoad If CompareEq SubscriptLoad NameLoad Index Str Str body Assign NameStore Str orelse If CompareEq SubscriptLoad NameLoad Index Str Str body Assign NameStore Str orelse If CompareEq SubscriptLoad NameLoad Index Str Str body Assign NameStore Str orelse If CompareEq SubscriptLoad NameLoad Index Str Str body Assign NameStore Str orelse Assign NameStore Str Assign SubscriptStore NameLoad Index Str Call AttributeLoad Str attr NameLoad NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Str NameLoad Expr Call AttributeLoad NameLoad attr Str NameLoad Expr Call AttributeLoad NameLoad attr Str Dict Expr Call AttributeLoad NameLoad attr Str Dict Expr Call AttributeLoad NameLoad attr Str Dict Expr Call AttributeLoad NameLoad attr Str Str Expr Call AttributeLoad NameLoad attr Str NameLoad Expr Call AttributeLoad NameLoad attr Str NameLoad Expr Call AttributeLoad NameLoad attr Str NameLoad Return NameLoad decorator_list FunctionDef arguments args defaults body Expr Str Assign NameStore Num Assign NameStore Call NameLoad Assign NameStore Call AttributeLoad NameLoad attr Str If UnaryOpNot NameLoad body Return NameLoad Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad NameLoad attr Str For NameStore NameLoad body Assign NameStore Call NameLoad NameLoad If UnaryOpNot Call SubscriptLoad NameLoad Index Str BinOpAdd SubscriptLoad NameLoad Index Str Str body If SubscriptLoad NameLoad Index Str body Assign NameStore BinOpMod Str TupleLoad SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad keyword NameLoad keyword Num If CompareNotEq NameLoad Num body Assign NameStore Num Continue Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad keyword NameLoad keyword Num keyword SubscriptLoad NameLoad Index Str Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad keyword NameLoad keyword Num keyword SubscriptLoad NameLoad Index Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad NameLoad Index Str Str Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str Assign NameStore Call NameLoad NameLoad Str Expr Call AttributeLoad NameLoad attr BinOpAdd NameLoad Str Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad Num Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore AttributeLoad Call AttributeLoad NameLoad attr NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Num orelse Assign NameStore BinOpMod Str SubscriptLoad NameLoad Index Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad keyword NameLoad keyword Num If CompareNotEq NameLoad Num body Assign NameStore Num Continue Expr Call SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str Num Assign NameStore BinOpMod Str NameLoad Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad keyword SubscriptLoad NameLoad Index Str keyword NameLoad keyword Num If CompareNotEq NameLoad Num body Assign NameStore Num If SubscriptLoad NameLoad Index Str body Assign NameStore Str orelse Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad keyword SubscriptLoad NameLoad Index Str keyword NameLoad keyword Num If CompareNotEq NameLoad Num body Assign NameStore Num Return NameLoad decorator_list FunctionDef arguments args defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Num Assign NameStore Dict For NameStore NameLoad body If CompareNotIn NameLoad NameLoad body Assign SubscriptStore NameLoad Index NameLoad Dict Assign SubscriptStore SubscriptLoad NameLoad Index NameLoad Index Str Call SubscriptLoad NameLoad Index Str NameLoad Assign SubscriptStore SubscriptLoad NameLoad Index NameLoad Index Str Call SubscriptLoad NameLoad Index Str NameLoad Return Dict Str Str NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad keyword Str For NameStore NameLoad body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If CompareNotEq NameLoad Num body Continue Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If CompareNotEq NameLoad Num body Return NameLoad Assign NameStore ListLoad Assign NameStore Call NameLoad NameLoad Str For NameStore Call AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad NameLoad attr Str If CompareEq Call AttributeLoad SubscriptLoad NameLoad Index Num attr Str body Expr Call AttributeLoad NameLoad attr Call AttributeLoad SubscriptLoad NameLoad Index Num attr Expr Call AttributeLoad NameLoad attr If NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad SubscriptLoad NameLoad Index Str Assign NameStore Call NameLoad NameLoad Str For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr orelse Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If UnaryOpNot NameLoad body Return Num Assign NameStore Call NameLoad NameLoad Str For NameStore NameLoad body Assign NameStore Call AttributeLoad Str attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If CompareNotEq NameLoad Num body Return NameLoad Return Num decorator_list FunctionDef arguments args defaults body Return Call AttributeLoad AttributeLoad NameLoad attr attr Str decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Str Return Call SubscriptLoad NameLoad Index Str NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str If UnaryOpNot Call NameLoad body Return Num Assign NameStore Str If CompareNotEq Call SubscriptLoad NameLoad Index Str NameLoad NameLoad Str body Assign NameStore Call NameLoad NameLoad If CompareNotEq NameLoad Num body Return NameLoad Assign NameStore Str Return Call SubscriptLoad NameLoad Index Str NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad body Expr Str If NameLoad body Assign NameStore Str Assign NameStore Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str NameLoad orelse Assign NameStore Call AttributeLoad Str attr SubscriptLoad NameLoad Index Str NameLoad Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad If CompareNotEq NameLoad Num body Return NameLoad Assign NameStore Call NameLoad NameLoad NameLoad keyword NameLoad If CompareNotEq NameLoad Num body Return NameLoad Assign NameStore Call NameLoad NameLoad NameLoad NameLoad keyword NameLoad keyword NameLoad If CompareNotEq NameLoad Num body Return NameLoad Return Num decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call NameLoad NameLoad Assign NameStore ListLoad For NameStore SubscriptLoad NameLoad Index Str body Expr Call AttributeLoad NameLoad attr Call SubscriptLoad NameLoad Index Str NameLoad Expr Call NameLoad Str NameLoad Assign NameStore Call NameLoad NameLoad If UnaryOpNot NameLoad body Return Dict Str Str Str Num NameLoad NameLoad If UnaryOpNot Call SubscriptLoad NameLoad Index Str BinOpAdd SubscriptLoad NameLoad Index Str Str body Assign NameStore Call NameLoad NameLoad SubscriptLoad NameLoad Index Str NameLoad If CompareNotEq NameLoad Num body Return Dict Str Str Str NameLoad NameLoad NameLoad orelse Assign NameStore Call NameLoad NameLoad SubscriptLoad NameLoad Index Str If CompareNotEq NameLoad Num body Return Dict Str Str Str NameLoad NameLoad NameLoad Assign NameStore Call AttributeLoad Str attr NameLoad Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad keyword SubscriptLoad NameLoad Index Str If CompareNotEq NameLoad Num body Return Dict Str Str Str NameLoad NameLoad NameLoad If SubscriptLoad NameLoad Index Str body Assign NameStore BinOpAdd SubscriptLoad NameLoad Index Str Str If UnaryOpNot Call SubscriptLoad NameLoad Index Str NameLoad body Assign NameStore Call NameLoad NameLoad SubscriptLoad NameLoad Index Str NameLoad keyword NameLoad If CompareNotEq NameLoad Num body Return Dict Str Str Str NameLoad NameLoad NameLoad orelse Assign NameStore Call NameLoad NameLoad SubscriptLoad NameLoad Index Str keyword NameLoad If CompareNotEq NameLoad Num body Return Dict Str Str Str NameLoad NameLoad NameLoad Assign NameStore Call NameLoad NameLoad SubscriptLoad NameLoad Index Str NameLoad keyword NameLoad keyword NameLoad If CompareNotEq NameLoad Num body Return Dict Str Str Str NameLoad NameLoad NameLoad For TupleStore NameStore NameStore Call AttributeLoad SubscriptLoad NameLoad Index Str attr body Assign NameStore Call NameLoad NameLoad NameLoad Expr Call SubscriptLoad NameLoad Index NameLoad NameLoad Return Dict Str Str Str Str NameLoad NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If CompareNotEq NameLoad Num body Return NameLoad Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If CompareNotEq NameLoad Num body Return NameLoad If SubscriptLoad NameLoad Index Str body Assign NameStore Call NameLoad NameLoad NameLoad NameLoad If CompareNotEq NameLoad Num body Return NameLoad Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If CompareNotEq NameLoad Num body Return NameLoad Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If CompareNotEq NameLoad Num body Return NameLoad Return Num decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore BinOpAdd SubscriptLoad NameLoad Index Str Str TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr handlers ExceptHandler type NameLoad body Return NameLoad TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore SubscriptLoad NameLoad Index Str handlers ExceptHandler type TupleLoad NameLoad NameLoad body Return NameLoad If Call AttributeLoad NameLoad attr Str NameLoad body Return NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str Assign NameStore Call NameLoad NameLoad Assign NameStore ListLoad Assign NameStore Num Expr Call NameLoad Str NameLoad Assign NameStore Call NameLoad NameLoad If UnaryOpNot NameLoad body Return Dict Str Str Str NameLoad NameLoad NameLoad Assign NameStore Call NameLoad NameLoad SubscriptLoad NameLoad Index Str NameLoad NameLoad If CompareNotEq NameLoad Num body Return Dict Str Str Str Str NameLoad NameLoad NameLoad NameLoad For TupleStore NameStore NameStore Call AttributeLoad SubscriptLoad NameLoad Index Str attr body Assign NameStore Call NameLoad NameLoad NameLoad Expr Call SubscriptLoad NameLoad Index NameLoad NameLoad Return Dict Str Str Str Str NameLoad NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body Expr Str For NameStore SubscriptLoad NameLoad Index Str body Expr Call AttributeLoad NameLoad attr Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If NameLoad body Assign NameStore BinOpMod Str NameLoad Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If CompareNotEq NameLoad Num body Return Num orelse Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr If CompareEq NameLoad NameLoad body Return Num Assign NameStore BinOpMod Str NameLoad Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If CompareNotEq NameLoad Num body Return Num If SubscriptLoad NameLoad Index Str body Assign NameStore Call NameLoad NameLoad NameLoad NameLoad If CompareNotEq NameLoad Num body Return NameLoad Assign NameStore Str Assign NameStore Call SubscriptLoad NameLoad Index Str NameLoad NameLoad If CompareNotEq NameLoad Num body Return Num If SubscriptLoad NameLoad Index Str body Assign NameStore Call NameLoad NameLoad If CompareNotEq NameLoad Num body Return NameLoad Return Num decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call NameLoad NameLoad Expr Call NameLoad Str NameLoad Assign NameStore ListLoad For NameStore SubscriptLoad NameLoad Index Str body Expr Call AttributeLoad NameLoad attr Call SubscriptLoad NameLoad Index Str NameLoad If SubscriptLoad NameLoad Index Str body Assign NameStore Call SubscriptLoad NameLoad Index Str SubscriptLoad NameLoad Index Str Return Dict Str Str Str NameLoad NameLoad NameLoad orelse Return Dict decorator_list
N/A N/A 
Run git deployment commands
 N/A redis N/A time N/A re N/A urllib N/A os N/A json N/A pwd N/A salt _get_redis_serv N/A N/A N/A N/A N/A 
    Return a redis server object

    :rtype: A Redis object
     N/A deployment_config N/A N/A __pillar__ get deployment_config N/A deploy_redis N/A deployment_config N/A redis N/A socket_connect_timeout N/A N/A deploy_redis get socket_connect_timeout N/A N/A socket_connect_timeout None N/A N/A socket_connect_timeout N/A int socket_connect_timeout N/A serv N/A N/A redis Redis host N/A deploy_redis N/A host port N/A int N/A deploy_redis N/A port db N/A int N/A deploy_redis N/A db socket_connect_timeout socket_connect_timeout N/A serv N/A _check_in N/A N/A function repo N/A N/A N/A 
    Private function used for reporting that a function has started.
    Writes to redis with basic status information.

    :param function: The function being reported on.
    :type function: str
    :param repo: The repository being acted on.
    :type repo: str
    :rtype: None
     N/A serv N/A _get_redis_serv N/A minion N/A N/A __grains__ get id N/A timestamp N/A N/A time time N/A N/A N/A serv sadd deploy:repos repo N/A N/A N/A serv sadd N/A N/A deploy:{0}:minions format repo minion N/A minion_key N/A N/A deploy:{0}:minions:{1} format repo minion N/A N/A function deploy.fetch N/A N/A N/A N/A serv hset minion_key fetch_checkin_timestamp timestamp N/A N/A N/A function deploy.checkout N/A N/A N/A N/A serv hset minion_key checkout_checkin_timestamp timestamp N/A N/A N/A function deploy.restart N/A N/A N/A N/A serv hset minion_key restart_checkin_timestamp timestamp N/A _map_args N/A N/A repo args N/A N/A N/A 
    Maps a set of arguments to a predefined set of values. Currently only
    __REPO__ is support and will be replaced with the repository name.

    :param repo: The repo name used for mapping.
    :type repo: str
    :param args: An array of arguments to map.
    :type args: list
    :rtype: list
     N/A arg_map N/A __REPO__ repo N/A mapped_args N/A N/A arg args N/A N/A N/A N/A mapped_args append N/A N/A arg_map get arg arg N/A mapped_args N/A get_config N/A N/A repo N/A N/A N/A 
    Fetches the configuration for this repo from the pillars and returns
    a hash with the munged configuration (with defaults and helper config).

    :param repo: The specific repo for which to return config data.
    :type repo: str
    :rtype: hash
     N/A deployment_config N/A N/A __pillar__ get deployment_config N/A config N/A N/A __pillar__ get repo_config N/A config N/A config N/A repo N/A N/A N/A config setdefault type git-http N/A N/A location config N/A N/A location N/A config N/A location N/A shadow_location N/A N/A {0}/.{1} format N/A N/A N/A os path dirname location N/A N/A N/A os path basename location N/A N/A config N/A shadow_location shadow_location N/A N/A location N/A N/A {0}/{1} format N/A deployment_config N/A parent_dir repo N/A N/A config N/A location location N/A shadow_repo N/A N/A {0}/.{1} format N/A N/A N/A os path dirname repo N/A N/A N/A os path basename repo N/A shadow_location N/A N/A {0}/{1} format N/A deployment_config N/A parent_dir shadow_repo N/A N/A config N/A shadow_location shadow_location N/A site N/A N/A __grains__ get site N/A server N/A N/A deployment_config N/A servers N/A site N/A N/A N/A config N/A type git-http N/A N/A scheme http N/A N/A N/A N/A config N/A type git-https N/A N/A scheme https N/A N/A N/A N/A config N/A type git-ssh N/A N/A scheme ssh N/A N/A N/A N/A config N/A type git N/A N/A scheme git N/A N/A scheme http N/A N/A config N/A url N/A N/A {0}://{1}/{2} format scheme server repo N/A N/A N/A config setdefault checkout_submodules False N/A N/A N/A config setdefault gitfat_enabled False N/A N/A N/A config setdefault dependencies N/A N/A N/A N/A config setdefault fetch_module_calls N/A N/A N/A N/A config setdefault checkout_module_calls N/A N/A N/A N/A config setdefault sync_script shared.py N/A N/A N/A config setdefault upstream None N/A N/A N/A config setdefault shadow_reference False N/A N/A N/A config setdefault service_name None N/A config N/A deployment_server_init N/A N/A N/A N/A N/A 
    Initializes a set of repositories on the deployment server. This
    function will only run on the deployment server and will initialize
    any repository defined in the pillar configuration. This function is
    safe to call at any point.

    :rtype: int
     N/A ret_status 0 N/A serv N/A _get_redis_serv N/A is_deployment_server N/A N/A __grains__ get deployment_server N/A N/A is_deployment_server N/A N/A ret_status N/A deploy_user N/A N/A __grains__ get deployment_repo_user N/A repo_config N/A N/A __pillar__ get repo_config N/A repo repo_config N/A N/A config N/A get_config repo N/A N/A N/A N/A __salt__ N/A file.directory_exists N/A N/A config N/A location /.git N/A N/A N/A config N/A upstream N/A N/A cmd N/A /usr/bin/git clone %s/.git %s N/A N/A config N/A upstream N/A config N/A location N/A status N/A N/A __salt__ N/A cmd.retcode cmd runas deploy_user umask 2 N/A N/A status 0 N/A N/A ret_status 1 N/A N/A cmd /usr/bin/git submodule update --init --recursive N/A status N/A N/A __salt__ N/A cmd.retcode cmd runas deploy_user umask 2 cwd N/A config N/A location N/A cmd git submodule foreach --recursive 'cd $(sed "s/^gitdir: //" .git) && git update-server-info' N/A status N/A N/A __salt__ N/A cmd.retcode cmd runas deploy_user umask 2 cwd N/A config N/A location N/A hook_directory N/A N/A N/A os path join N/A config N/A location .git hooks N/A post_checkout_path N/A N/A N/A os path join hook_directory post-checkout N/A post_checkout N/A open post_checkout_path w N/A N/A N/A post_checkout write N/A cmd N/A N/A N/A post_checkout close N/A N/A N/A os chmod post_checkout_path 775 N/A post_commit_path N/A N/A N/A os path join hook_directory post-commit N/A N/A N/A os symlink post_checkout_path post_commit_path N/A deploy_uid N/A N/A N/A pwd getpwnam deploy_user pw_uid N/A N/A N/A os chown post_checkout_path deploy_uid -1 N/A N/A N/A os lchown post_commit_path deploy_uid -1 N/A N/A cmd N/A /usr/bin/git init %s N/A config N/A location N/A status N/A N/A __salt__ N/A cmd.retcode cmd runas deploy_user umask 2 N/A N/A status 0 N/A N/A ret_status 1 N/A N/A N/A N/A __salt__ N/A file.set_mode N/A config N/A location 2775 N/A cmd N/A git config deploy.repo-name %s repo N/A status N/A N/A __salt__ N/A cmd.retcode cmd cwd N/A config N/A location runas deploy_user umask 2 N/A N/A status 0 N/A N/A ret_status 1 N/A N/A config N/A checkout_submodules N/A N/A cmd git config deploy.checkout-submodules true N/A N/A cmd git config deploy.checkout-submodules false N/A status N/A N/A __salt__ N/A cmd.retcode cmd cwd N/A config N/A location runas deploy_user umask 2 N/A N/A status 0 N/A N/A ret_status 1 N/A ret_status N/A sync_all N/A N/A N/A N/A N/A 
    Sync all repositories for this minion. If a repo doesn't exist on target,
    clone it as well. This function will ensure all repositories for the
    minion are at the current tag as defined by the master and is
    be safe to call at any point.

    CLI Example (from the master):

        salt -G 'deployment_target:test' deploy.sync_all

    CLI Example (from a minion):

        salt-call deploy.sync_all

    :rtype: hash
     N/A repo_config N/A N/A __pillar__ get repo_config N/A deployment_target N/A N/A __grains__ get deployment_target N/A status 0 N/A stats N/A N/A repo repo_config N/A N/A N/A repo stats N/A N/A N/A stats N/A repo N/A N/A N/A N/A stats N/A repo N/A deploy.fetch N/A N/A __salt__ N/A deploy.fetch repo N/A N/A N/A stats N/A repo N/A deploy.checkout N/A N/A __salt__ N/A deploy.checkout repo N/A N/A status stats status stats N/A _update_gitmodules N/A N/A config location shadow N/A False N/A N/A 
    Finds all .gitmodules in a repository, changes all submodules within them
    to point to the correct submodule on the deployment server, then runs
    a submodule sync. This function is in support of recursive submodules.

    In the case we need to update a shadow reference repo, the .gitmodules
    files will have their submodules point to the reference clone.

    :param config: The config hash for the repo (as pulled from get_config).
    :type config: hash
    :param location: The location on the filesystem to find the .gitmodules
                     files.
    :type location: str
    :param shadow: Defines whether or not this is a shadow reference repo.
    :type shadow: bool
    :rtype: int
     N/A gitmodules_list N/A N/A __salt__ N/A file.find location name .gitmodules N/A gitmodules gitmodules_list N/A N/A gitmodules_dir N/A N/A N/A os path dirname gitmodules N/A cmd /usr/bin/git submodule status --quiet N/A status N/A N/A __salt__ N/A cmd.retcode cmd gitmodules_dir N/A N/A status 0 N/A N/A N/A cmd /usr/bin/git checkout .gitmodules N/A status N/A N/A __salt__ N/A cmd.retcode cmd gitmodules_dir N/A N/A status 0 N/A N/A status N/A submodules N/A N/A f N/A open gitmodules r N/A line N/A N/A f readlines N/A N/A keyval N/A N/A line split  =  N/A N/A N/A N/A N/A keyval N/A 0 strip path N/A N/A N/A N/A submodules append N/A N/A N/A keyval N/A 1 strip N/A N/A N/A f close N/A shadow N/A N/A reference_dir N/A N/A gitmodules_dir replace location N/A config N/A location N/A f N/A open gitmodules w N/A submodule submodules N/A N/A N/A N/A f write N/A N/A [submodule "{0}"]
 format submodule N/A N/A N/A f write N/A N/A 	path = {0}
 format submodule N/A N/A N/A f write N/A N/A 	url = {0}/{1}
 format reference_dir submodule N/A N/A N/A f close N/A N/A cmd /usr/bin/git config remote.origin.url N/A remote N/A N/A __salt__ N/A cmd.run cmd gitmodules_dir N/A N/A remote N/A N/A 1 N/A f N/A open gitmodules w N/A submodule submodules N/A N/A submodule_path N/A N/A modules/{0} format submodule N/A N/A N/A f write N/A N/A [submodule "{0}"]
 format submodule N/A N/A N/A f write N/A N/A 	path = {0}
 format submodule N/A N/A N/A f write N/A N/A 	url = {0}/{1}
 format remote submodule_path N/A N/A N/A f close N/A cmd /usr/bin/git submodule sync N/A status N/A N/A __salt__ N/A cmd.retcode cmd gitmodules_dir N/A N/A status 0 N/A N/A status N/A 0 N/A _gitfat_installed N/A N/A N/A N/A N/A N/A N/A N/A salt utils which git-fat N/A _init_gitfat N/A N/A location N/A N/A N/A 
    Runs git fat init at this location.

    :param location: The location on the filesystem to run git fat init
    :type location: str
     N/A cmd /usr/bin/git fat init N/A N/A N/A __salt__ N/A cmd.retcode cmd location N/A _update_gitfat N/A N/A location N/A N/A N/A 
    Runs git-fat pull at this location.
    If git fat has not been initialized for the
    repository at this location, _init_gitfat
    will be called first.

    :param location: The location on the filesystem to run git fat pull
    :type location: str
    :rtype int
     N/A N/A N/A _gitfat_installed N/A N/A 40 N/A cmd /usr/bin/git config --get filter.fat.smudge N/A N/A N/A N/A __salt__ N/A cmd.run cmd location git-fat filter-smudge N/A N/A status N/A _init_gitfat location N/A N/A status 0 N/A N/A status N/A cmd /usr/bin/git fat pull N/A N/A N/A __salt__ N/A cmd.retcode cmd location N/A _clone N/A N/A config location tag shadow N/A False N/A N/A 
    Perform a clone of a repo at a specified location, and
    do a fetch and checkout of the repo to ensure it's at the
    current deployment tag.

    :param config: Config hash as fetched from get_config
    :type config: hash
    :param location: The location on the filesystem to clone this repo.
    :type location: str
    :param tag: The tag to ensure this clone is checked out to.
    :type tag: str
    :param shadow: Whether or not this repo is a shadow reference.
    :type shadow: bool
    :rtype: int
     N/A shadow N/A N/A cmd /usr/bin/git clone --reference {0} {1}/.git {2} N/A cmd N/A N/A cmd format N/A config N/A location N/A config N/A url location N/A N/A cmd N/A N/A /usr/bin/git clone {0}/.git {1} format N/A config N/A url location N/A status N/A N/A __salt__ N/A cmd.retcode cmd N/A N/A status 0 N/A N/A status N/A status N/A _fetch_location config location shadow shadow N/A N/A status 0 N/A N/A status N/A status N/A _checkout_location config location tag reset True shadow shadow N/A N/A status 0 N/A N/A status N/A 0 N/A fetch N/A N/A repo N/A N/A N/A 
    Call a fetch for the specified repo

    CLI Example (from the master):

        salt -G 'deployment_target:test' deploy.fetch 'test/testrepo'

    CLI Example (from the minion):

        salt-call deploy.fetch 'test/testrepo'

    :param repo: The repo on which to perform the fetch.
    :type repo: str
    :rtype: hash
     N/A config N/A get_config repo N/A depstats N/A N/A dependency N/A config N/A dependencies N/A N/A N/A N/A depstats append N/A N/A __salt__ N/A deploy.fetch dependency N/A N/A _check_in deploy.fetch repo N/A tag N/A _get_tag config N/A N/A tag N/A N/A N/A status repo dependencies 10 repo depstats N/A N/A N/A N/A __salt__ N/A file.directory_exists N/A N/A config N/A location /.git N/A N/A status N/A _clone config N/A config N/A location tag N/A N/A status 0 N/A N/A N/A status repo dependencies status repo depstats N/A N/A status N/A _fetch_location config N/A config N/A location N/A N/A status 0 N/A N/A N/A status repo dependencies status repo depstats N/A cmd N/A N/A /usr/bin/git show-ref refs/tags/{0} format tag N/A status N/A N/A __salt__ N/A cmd.retcode cmd cwd N/A config N/A location N/A N/A status 0 N/A N/A N/A status repo dependencies status repo depstats N/A N/A config N/A shadow_reference N/A N/A shadow_gitdir N/A N/A config N/A shadow_location /.git N/A N/A N/A N/A __salt__ N/A file.directory_exists shadow_gitdir N/A N/A status N/A _clone config N/A config N/A shadow_location tag shadow True N/A N/A status 0 N/A N/A N/A status repo dependencies status repo depstats N/A N/A status N/A _fetch_location config N/A config N/A shadow_location shadow True N/A N/A status 0 N/A N/A N/A status repo dependencies status repo depstats N/A status N/A _checkout_location config N/A config N/A shadow_location tag reset False shadow True N/A N/A status 0 N/A N/A N/A status repo dependencies status repo depstats N/A N/A call args N/A N/A N/A config N/A fetch_module_calls items N/A N/A mapped_args N/A _map_args repo args N/A N/A N/A __salt__ N/A call mapped_args N/A N/A status repo dependencies tag status repo depstats tag N/A _fetch_location N/A N/A config location shadow N/A False N/A N/A 
    Fetch a repo at a specified location. Optionally define this repo as a
    shadow repo.

    :param config: Config hash as fetched from get_config.
    :type config: hash
    :param location: The location on the filesystem to run the fetch.
    :type location: str
    :rtype: int
     N/A cmd /usr/bin/git fetch N/A status N/A N/A __salt__ N/A cmd.retcode cmd location N/A N/A status 0 N/A N/A status N/A cmd /usr/bin/git fetch --tags N/A status N/A N/A __salt__ N/A cmd.retcode cmd location N/A N/A status 0 N/A N/A status N/A N/A config N/A checkout_submodules N/A N/A ret N/A _update_gitmodules config location shadow N/A N/A ret 0 N/A N/A ret N/A cmd /usr/bin/git submodule foreach --recursive git fetch N/A status N/A N/A __salt__ N/A cmd.retcode cmd location N/A N/A status 0 N/A N/A status N/A cmd /usr/bin/git submodule foreach --recursive git fetch --tags N/A status N/A N/A __salt__ N/A cmd.retcode cmd location N/A N/A status 0 N/A N/A status N/A 0 N/A _get_tag N/A N/A config N/A N/A N/A 
    Fetch the current deploy file from the repo on the deployment server and
    return the current tag associated with it.

    :param config: Config hash as fetched from get_config.
    :type config: hash
    :rtype: str
     N/A deployfile N/A N/A config N/A url /.git/deploy/deploy N/A N/A N/A f N/A N/A urllib urlopen deployfile N/A deployinfo N/A N/A f read N/A N/A N/A IOError N/A N/A None N/A N/A N/A deployinfo N/A N/A json loads deployinfo N/A tag N/A deployinfo N/A tag N/A N/A N/A N/A KeyError ValueError N/A N/A None N/A N/A N/A re search [^a-zA-Z0-9_\-/] tag N/A N/A None N/A tag N/A checkout N/A N/A repo reset N/A False N/A N/A 
    Checkout the current deployment tag. Assumes a fetch has been run.

    CLI Example (on master):

        salt -G 'deployment_target:test' deploy.checkout 'test/testrepo'

    CLI Example (on minion):

        salt deploy.checkout 'test/testrepo'

    :param repo: The repo name to check out.
    :type repo: str
    :param reset: Whether or not to do a checkout and hard reset based
                  on if the repo is already at the defined tag on the
                  deployment server.
    :type reset: bool
    :rtype: hash
     N/A config N/A get_config repo N/A depstats N/A N/A status -1 N/A N/A _check_in deploy.checkout repo N/A tag N/A _get_tag config N/A N/A tag N/A N/A N/A status repo dependencies status repo depstats N/A status N/A _checkout_location config N/A config N/A location tag reset N/A N/A status 0 N/A N/A N/A status repo tag dependencies status repo tag depstats N/A N/A call args N/A N/A N/A config N/A checkout_module_calls items N/A N/A mapped_args N/A _map_args repo args N/A N/A N/A __salt__ N/A call mapped_args N/A N/A status repo tag dependencies status repo tag depstats N/A _checkout_location N/A N/A config location tag reset shadow N/A False False N/A N/A 
    Checkout a repo at the specified location to the specified tag. If reset
    is true checkout the repo even if it is already at the tag defined on the
    deployment server. Optionally specify if this is a shadow reference repo.

    :param config: Config hash as fetched from get_config.
    :type config: hash
    :param location: The location on the filesystem to run this checkout.
    :type location: str
    :param tag: The tag to checkout this location to.
    :type tag: str
    :param reset: Whether or not to checkout this repo if it is already at the
                  tag specified by the deployment server.
    :type reset: bool
    :param shadow: Whether or not this is a shadow reference repo.
    :type shadow: bool
    :rtype: int
     N/A dependency N/A config N/A dependencies N/A N/A N/A N/A depstats append N/A N/A __salt__ N/A deploy.checkout dependency reset N/A reset N/A N/A cmd N/A /usr/bin/git reset --hard tags/%s tag N/A ret N/A N/A __salt__ N/A cmd.retcode cmd location N/A N/A ret 0 N/A N/A 20 N/A N/A cmd /usr/bin/git describe --always --tag N/A current_tag N/A N/A __salt__ N/A cmd.run cmd location N/A current_tag N/A N/A current_tag strip N/A N/A current_tag tag N/A N/A 0 N/A cmd N/A /usr/bin/git checkout --force --quiet tags/%s tag N/A ret N/A N/A __salt__ N/A cmd.retcode cmd location N/A N/A ret 0 N/A N/A 30 N/A N/A config N/A checkout_submodules N/A N/A ret N/A _update_gitmodules config location shadow N/A N/A ret 0 N/A N/A ret N/A cmd /usr/bin/git submodule update --recursive --init N/A ret N/A N/A __salt__ N/A cmd.retcode cmd location N/A N/A ret 0 N/A N/A 50 N/A N/A config N/A gitfat_enabled N/A N/A ret N/A _update_gitfat location N/A N/A ret 0 N/A N/A ret N/A 0 N/A restart N/A N/A repo N/A N/A N/A 
    Restart the service associated with this repo.

    CLI Example (on the master):

        salt -G 'deployment_target:test' deploy.restart 'test/testrepo'

    CLI Example (on the minion):

        salt-call deploy.restart 'test/testrepo'

    :param repo: The repo name used to find the service to restart.
    :type repo: str
    :rtype: hash
     N/A config N/A get_config repo N/A N/A _check_in deploy.restart repo N/A depstats N/A N/A dependency N/A config N/A dependencies N/A N/A N/A N/A depstats append N/A N/A __salt__ N/A deploy.restart dependency N/A N/A config N/A service_name N/A N/A status N/A N/A __salt__ N/A service.restart N/A config N/A service_name N/A N/A status repo dependencies status repo depstats N/A N/A N/A N/A