-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add prototypes of some basic functions to be used
- Loading branch information
Showing
1 changed file
with
23 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,29 @@ | ||
"""Main module for ansible-deploy""" | ||
|
||
import sys | ||
|
||
def get_sub_command(): | ||
"""Function to check the first arguments (argv[1..]) looking for a subcommand""" | ||
|
||
def parse_options(): | ||
"""Generic function to parse options for all commands, we validate if the option was allowed for | ||
specific subcommand outside""" | ||
|
||
def validate_options(options, subcommand): | ||
"""Function checking if the options set are allowed in this subcommand""" | ||
|
||
def load_configuration(): | ||
"""Function responsible for reading configuration files and running a schema validator against | ||
it""" | ||
|
||
def validate_user_infra_stage(): | ||
"""Function checking if user has rights to execute command on selected infrastructure | ||
Required for: run, lock and unlock operations""" | ||
|
||
def validate_user_task(): | ||
"""Function checking if user has rights to execute the task | ||
Rquired for: run""" | ||
|
||
def main(): | ||
"""ansible-deploy endpoint function""" | ||
sys.exit(0) |