From 535ea87033e2307d6b3d34bbdc97d7becc46fbf0 Mon Sep 17 00:00:00 2001 From: pkazi Date: Mon, 17 Sep 2018 14:50:13 +0530 Subject: [PATCH] Update README --- README.md | 6 ++- mesos/01-NodeAttributes.md | 2 +- mesos/README.md | 5 +++ utils/README.md | 81 ++++++++++++++++++++++++++++++++++++++ 4 files changed, 92 insertions(+), 2 deletions(-) create mode 100644 mesos/README.md create mode 100644 utils/README.md diff --git a/README.md b/README.md index 0c192a8..0b73944 100644 --- a/README.md +++ b/README.md @@ -1 +1,5 @@ -# DCOS Toolkit \ No newline at end of file +# DCOS Toolkit + +## Everything related to mesos are listed here. + +1. [Mesos](mesos/README.md) \ No newline at end of file diff --git a/mesos/01-NodeAttributes.md b/mesos/01-NodeAttributes.md index 8090373..206ead7 100644 --- a/mesos/01-NodeAttributes.md +++ b/mesos/01-NodeAttributes.md @@ -1,4 +1,4 @@ -# DC/OS Add node Attributes +# DCOS Toolkit - Mesos - Add node Attributes - To use marathon constraints, we can specify attributes to every mesos node. - Attributes are defined in key:value pairs and node can have multiple attributes. diff --git a/mesos/README.md b/mesos/README.md new file mode 100644 index 0000000..40dd077 --- /dev/null +++ b/mesos/README.md @@ -0,0 +1,5 @@ +# DCOS Toolkit - Mesos + +## Tips and Tricks related to mesos are listed here + +1. [Mesos Node Attributes](01-NodeAttributes.md) \ No newline at end of file diff --git a/utils/README.md b/utils/README.md new file mode 100644 index 0000000..ac3be5b --- /dev/null +++ b/utils/README.md @@ -0,0 +1,81 @@ +# DCOS Toolkit - Utils + +## Utility scripts for dcos, mesos, marathon and other dcos services + +### [dcosUtil.sh](dcosUtil.sh) + +```text +=================== += DCOS Util Usage = +=================== +Please input any one operation from : [ help addAWSKey agentsDetails publicIP saveMarathonConfig appsReport nodes nodeSsh taskNodeSsh taskExec tasksByNode switchCluster cleanService getUsers addUsers deleteUsers getConstraints getZNodeData runOnAllAgents runOnAllMasters runOnLeader ] +- Below operations are supported : + - help + - Get help for this utility script. + - Usage : `bash dcosUtil.sh help` + - addAWSKey + - Add the private key of dcos cluster to ssh. Fetches KeyName using aws cli and add if it exits in $HOME/.ssh folder + - Usage : `bash dcosUtil.sh addAWSKey` + - agentsDetails + - Get the list of Public and Private agents along with IP addresses and dcos node ID + - Usage : `bash dcosUtil.sh agentsDetails ` + - publicIP + - Get the Public IP of public and master nodes. + - Usage : `bash dcosUtil.sh publicIP ` + - nodes + - Get the list of nodes along with their type, private IP address, node attributes, number of tasks running, free mem and cpu. + - There will be a seperate node entry for each node attribute. + - Usage : `bash dcosUtil.sh nodes` + - saveMarathonConfig + - Download the marathon config of all the apps/services running on dcos cluster and save all json files. + - Usage : `bash dcosUtil.sh saveMarathonConfig ` + - appsReport + - This will display the docker image and tag used for each app/sevice of DCOS cluster + - Usage : `bash dcosUtil.sh appsReport` + - nodeSsh + - This will ssh to dcos node, need Private IP of node as input, if not specified will prompt for user to input + - Use 'leader' as Private IP input to ssh to master leader node. + - Usage : `bash dcosUtil.sh nodeSsh ` + - taskNodeSsh + - This will ssh to dcos node where task is running. Need task name as input. + - If more than 1 instance are running of the services, this will ssh to first instance's node. Give task ID as input for specific instance. + - Usage : `bash dcosUtil.sh taskNodeSsh ` + - taskExec + - This will run command inside container running for a task. Need task name / ID as input. + - If more than 1 instance are running of the services, this will ssh to first instance's node. Give task ID as input for specific instance. + - Usage : `bash dcosUtil.sh taskExec ` + - tasksByNode + - This will fetch the task name and task id running on perticular node. + - Need node ip as input. + - Usage : `bash dcosUtil.sh tasksByNode ` + - switchCluster + - Switch to other dcos cluster + - Usage : `bash dcosUtil.sh switchCluster ` + - cleanService + - Clean the service and its reserved resources from zookeeper using mesosphere janiter script + - Usage : `bash dcosUtil.sh cleanService ` + - getUsers + - Get the users which are added to cluster organization + - Usage : `bash dcosUtil.sh getUsers` + - addUsers + - Add users to cluster organization + - Usage : `bash dcosUtil.sh addUsers ` + - deleteUsers + - Delete users from cluster organization + - Usage : `bash dcosUtil.sh deleteUsers ` + - getConstraints + - Get the apps which are using placement constraints + - Usage : `bash dcosUtil.sh getConstraints` + - getZNodeData + - Get the data for MESOS Zookeeper Node. + - Usage : `bash dcosUtil.sh getZNodeData` + - runOnAllAgents + - Run user command on all dcos nodes + - Usage : `bash dcosUtil.sh runOnAllAgents ""` + - runOnLeader + - Run user command on dcos leader master + - Usage : `bash dcosUtil.sh runOnLeader ""` + - runOnAllMasters + - Run user command on all dcos master nodes + - Usage : `bash dcosUtil.sh runOnAllMasters ""` +``` \ No newline at end of file