Guest User

Untitled

a guest
Feb 18th, 2019
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. #!/bin/bash
  2. if [ "$ClusterName" == "$MongodbCluster1" ]
  3. then
  4. /bin/aws s3 cp s3://templates/mongodb/mongoactivenode.js /bin
  5. /bin/aws s3 cp s3://templates/mongodb/replicasetstatus.sh /bin
  6. chmod 777 /bin/replicasetstatus.sh
  7. chmod 777 /bin/mongoactivenode.js
  8.  
  9. echo '*/1 * * * * cd /bin/ && sudo /usr/bin/sh /bin/replicasetstatus.sh'
  10. else
  11. echo "Cannot be performed on secondary"
  12. fi
  13. exit 0
Add Comment
Please, Sign In to add comment