Aug
14

Watch Full Movie Online Night School (2018)

Watch Movie Online Night School (2018)

Night School

Released |Duration : 1 hours 31 minutes

0

DIRECTED BY : Malcolm D. Lee.

PRODUCED BY : William Packer.

GENRE : Drama, Comedy.

VIDEO : 720p.

LANGUAGE : English.

MORE INFO
PLOT SUMMARY

‘Night School’ is a movie genre Drama, was released in September 27, 2018. Malcolm D. Lee was directed this movie and starring by Kevin Hart. This movie tell story about A group of misfits are forced to attend adult classes to prepare for the GED exam.

CAST
YOU MAY ALSO LIKE

Prodigy (2018)

The Darkest Minds (2018)

Slave To The Grind (2018)

Children of the Corn: Runaway (2018)

55 Steps (2018)

Weekend (2018)

A Quiet Place (2018)

Life in a Year (2018)

The Post (2018)

Maison du bonheur (2018)

2036 Origin Unknown (2018)

Skyscraper (2018)

Love, Simon (2018)

Trench (2018)

Respiri (2018)

Padman (2018)

The Leisure Seeker (2018)

The Boy Downstairs (2018)

A Prayer Before Dawn (2018)

Cobain (2018)
Incoming search terms:
Night School 2018 movie trailer, streaming Night School film, Watch Night School 2018 Online Free hulu, movie Night School 2018 download, watch Night School movie online now, live streaming movie Night School 2018 online, live streaming film Night School online, Night School 2018 Watch Online, trailer movie Night School, Watch Night School 2018 Online 123movie, watch movie Night School online now, watch film Night School now, Watch Night School 2018 Online Free Viooz, Watch Night School 2018 For Free online, Watch Night School 2018 Online 123movies, film Night School 2018 trailer, Streaming Night School 2018 Online Free Megashare, film Night School, watch full movie Night School 2018, Watch Night School 2018 Online Free megashare, Watch Night School 2018 Online Megashare, watch Night School 2018 film now, watch full Night School film, Watch Night School 2018 Online Free netflix, Watch Night School 2018 Online Viooz, Watch Night School 2018 Online Putlocker, streaming movie Night School 2018, Streaming Night School 2018 For Free Online, Watch Night School 2018 Online Free 123movie, Watch Night School 2018 Online Free, trailer film Night School, Watch Night School 2018 Online Free Putlocker.
Jul
17

Watch Full Movie Crazy Rich Asians (2018)

Watch and Download Movie Crazy Rich Asians (2018)

Crazy Rich Asians

Released |Duration : 2 hours 1 minutes

7

DIRECTED BY : Jon M. Chu.

PRODUCED BY : Nina Jacobson, John Penotti.

GENRE : Drama, Comedy.

VIDEO : 720p.

LANGUAGE : English.

MORE INFO

PRODUCTION BY : Color Force, Ivanhoe Pictures.

PLOT SUMMARY

‘Crazy Rich Asians’ is a movie genre Drama, was released in August 15, 2018. Jon M. Chu was directed this movie and starring by Constance Wu. This movie tell story about An American-born Chinese economics professor accompanies her boyfriend to Singapore for his best friend’s wedding, only to get thrust into the lives of Asia’s rich and famous.

CAST
YOU MAY ALSO LIKE

Searching (2018)

Chappaquiddick (2018)

The Spy Who Dumped Me (2018)

Leave No Trace (2018)

Won’t You Be My Neighbor? (2018)

Eighth Grade (2018)

Peppermint (2018)

Operation Finale (2018)

Marainthirunthu Paarkum Marmam Enna (2018)

Maquia: When the Promised Flower Blooms (2018)

BlacKkKlansman (2018)

Three Identical Strangers (2018)

The Happytime Murders (2018)

Whitney (2018)

Mile 22 (2018)

Blindspotting (2018)

Book Club (2018)

Sorry to Bother You (2018)

Barsaat (1995)

Christopher Robin (2018)
Incoming search terms:
Crazy Rich Asians 2018 live streaming film, watch full movie Crazy Rich Asians online, Streaming Crazy Rich Asians 2018 Online Free Megashare, Watch Crazy Rich Asians 2018 Online Viooz, Watch Crazy Rich Asians 2018 Online Putlocker, Watch Crazy Rich Asians 2018 Online 123movies, live streaming film Crazy Rich Asians 2018 online, Streaming Crazy Rich Asians 2018 For Free Online, movie Crazy Rich Asians 2018 trailer, movie Crazy Rich Asians, watch full Crazy Rich Asians movie, download movie Crazy Rich Asians 2018, streaming Crazy Rich Asians 2018 film, Watch Crazy Rich Asians 2018 Online Megashare, streaming Crazy Rich Asians movie, Watch Crazy Rich Asians 2018 Online Free 123movie, Watch Crazy Rich Asians 2018 Online Free Putlocker, Crazy Rich Asians 2018 film download, Watch Crazy Rich Asians 2018 Online 123movie, Crazy Rich Asians 2018 movie download, Watch Crazy Rich Asians 2018 For Free online, film Crazy Rich Asians 2018, Crazy Rich Asians 2018 movie streaming, trailer movie Crazy Rich Asians 2018, Watch Crazy Rich Asians 2018 Online Free, Watch Crazy Rich Asians 2018 Online Free megashare, Watch Crazy Rich Asians 2018 Online Free netflix, film Crazy Rich Asians 2018 trailer, download Crazy Rich Asians 2018 movie, watch movie Crazy Rich Asians online now, movie Crazy Rich Asians 2018 download, Watch Crazy Rich Asians 2018 Online Free hulu, Watch Crazy Rich Asians 2018 Online Free Viooz, Crazy Rich Asians 2018 Watch Online.
Jul
13

Watch Full Movie Mission: Impossible – Fallout (2018)

Streaming Full Movie Mission: Impossible - Fallout (2018) Online

Mission: Impossible – Fallout

Released |Duration : 2 hours 27 minutes

7.3

DIRECTED BY : Christopher McQuarrie.

PRODUCED BY : J.J. Abrams, Tom Cruise.

GENRE : Drama, Adventure, Action, Thriller.

VIDEO : 720p.

LANGUAGE : English.

MORE INFO

COUNTRY : United States of America.

PRODUCTION BY : Paramount, Bad Robot, Skydance Media.

PLOT SUMMARY

Movie ‘Mission: Impossible – Fallout’ was released in July 25, 2018 in genre Drama. Christopher McQuarrie was directed this movie and starring by Tom Cruise. This movie tell story about When an IMF mission ends badly, the world is faced with dire consequences. As Ethan Hunt takes it upon himself to fulfil his original briefing, the CIA begin to question his loyalty and his motives. The IMF team find themselves in a race against time, hunted by assassins while trying to prevent a global catastrophe.

CAST
YOU MAY ALSO LIKE

Ant-Man and the Wasp (2018)

Jurassic World: Fallen Kingdom (2018)

Skyscraper (2018)

Solo: A Star Wars Story (2018)

Incredibles 2 (2018)

The Meg (2018)

Ready Player One (2018)

Ocean’s Eight (2018)

Deadpool 2 (2018)

Sicario: Day of the Soldado (2018)

BlacKkKlansman (2018)

The Spy Who Dumped Me (2018)

The Equalizer 2 (2018)

Avengers: Infinity War (2018)

A Quiet Place (2018)

Tomb Raider (2018)

Mile 22 (2018)

Rampage (2018)

Mission: Impossible – Rogue Nation (2015)

Game Night (2018)
Incoming search terms:
Streaming Mission: Impossible – Fallout 2018 Online Free Megashare, Watch Mission: Impossible – Fallout 2018 For Free online, Mission: Impossible – Fallout 2018 movie trailer, Watch Mission: Impossible – Fallout 2018 Online Viooz, film Mission: Impossible – Fallout streaming, Mission: Impossible – Fallout 2018 streaming, download full film Mission: Impossible – Fallout, film Mission: Impossible – Fallout 2018, Watch Mission: Impossible – Fallout 2018 Online Free megashare, Watch Mission: Impossible – Fallout 2018 Online Megashare, Watch Mission: Impossible – Fallout 2018 Online Free hulu, Watch Mission: Impossible – Fallout 2018 Online Free 123movie, Watch Mission: Impossible – Fallout 2018 Online Free Viooz, watch full Mission: Impossible – Fallout 2018 film, Watch Mission: Impossible – Fallout 2018 Online Putlocker, streaming Mission: Impossible – Fallout 2018 film, streaming Mission: Impossible – Fallout, Watch Mission: Impossible – Fallout 2018 Online Free Putlocker, watch full Mission: Impossible – Fallout 2018 film online, watch Mission: Impossible – Fallout movie now, Watch Mission: Impossible – Fallout 2018 Online 123movies, watch movie Mission: Impossible – Fallout 2018 online now, Watch Mission: Impossible – Fallout 2018 Online Free netflix, Streaming Mission: Impossible – Fallout 2018 For Free Online, Watch Mission: Impossible – Fallout 2018 Online Free, Mission: Impossible – Fallout 2018 film download, download full movie Mission: Impossible – Fallout 2018, live streaming film Mission: Impossible – Fallout online, Mission: Impossible – Fallout 2018 Watch Online, Mission: Impossible – Fallout 2018 film trailer, Watch Mission: Impossible – Fallout 2018 Online 123movie, Mission: Impossible – Fallout live streaming movie, movie Mission: Impossible – Fallout download.
Jun
25

Watch and Download Full Movie Searching (2018)

Streaming Movie Searching (2018) Online

Searching

Released |Duration : 1 hours 41 minutes

7.3

DIRECTED BY : Aneesh Chaganty.

PRODUCED BY : Natalie Qasabian, Adam Sidman.

GENRE : Drama, Thriller.

VIDEO : 720p.

LANGUAGE : English.

MORE INFO

PRODUCTION BY : Stage 6 Films, Bazelevs Production.

PLOT SUMMARY

Movie ‘Searching’ was released in August 24, 2018 in genre Drama. Aneesh Chaganty was directed this movie and starring by John Cho. This movie tell story about After his 16-year-old daughter goes missing, a desperate father breaks into her laptop to look for clues to find her. A thriller that unfolds entirely on computer screens.

CAST
YOU MAY ALSO LIKE

Operation Finale (2018)

Crazy Rich Asians (2018)

The Happytime Murders (2018)

Peppermint (2018)

Unfriended: Dark Web (2018)

The Spy Who Dumped Me (2018)

BlacKkKlansman (2018)

Mission: Impossible – Fallout (2018)

Skyscraper (2018)

Hereditary (2018)

Chappaquiddick (2018)

Hotel Artemis (2018)

The Meg (2018)
Incoming search terms:
Streaming Searching 2018 Online Free Megashare, watch full movie Searching online, Watch Searching 2018 Online Viooz, movie Searching trailer, Streaming Searching 2018 For Free Online, Watch Searching 2018 Online Free netflix, watch full Searching film online, Watch Searching 2018 Online Free Viooz, watch Searching 2018 film online now, Searching 2018 live streaming film, watch full Searching movie, download Searching 2018 movie now, trailer movie Searching, Searching 2018 Watch Online, Watch Searching 2018 Online Free hulu, Watch Searching 2018 Online Free Putlocker, Searching movie download, Searching 2018 live streaming film online, Searching movie, film Searching, download movie Searching now, Watch Searching 2018 For Free online, streaming Searching 2018, Watch Searching 2018 Online Megashare, Watch Searching 2018 Online Free 123movie, Watch Searching 2018 Online Free, Watch Searching 2018 Online 123movies, Watch Searching 2018 Online Putlocker, Searching movie trailer, streaming Searching 2018 film, download film Searching 2018 now, Watch Searching 2018 Online Free megashare, streaming movie Searching, Watch Searching 2018 Online 123movie, streaming film Searching, download full film Searching, live streaming movie Searching 2018.
Jun
24

Watch and Download Movie Eighth Grade (2018)

Streaming Movie Eighth Grade (2018)

Eighth Grade

Released |Duration : 1 hours 34 minutes

8.6

DIRECTED BY : Bo Burnham.

PRODUCED BY : Scott Rudin, Lila Yacoub.

GENRE : Drama, Comedy.

VIDEO : 720p.

LANGUAGE : English.

MORE INFO

COUNTRY : United States of America.

PRODUCTION BY : Scott Rudin Productions, A24.

PLOT SUMMARY

Movie ‘Eighth Grade’ was released in July 13, 2018 in genre Drama. Bo Burnham was directed this movie and starring by Elsie Fisher. This movie tell story about Thirteen-year-old Kayla endures the tidal wave of contemporary suburban adolescence as she makes her way through the last week of middle school — the end of her thus far disastrous eighth grade year — before she begins high school.

CAST
YOU MAY ALSO LIKE

Leave No Trace (2018)

Hearts Beat Loud (2018)

Three Identical Strangers (2018)

Won’t You Be My Neighbor? (2018)

Blindspotting (2018)

Whitney (2018)

Crazy Rich Asians (2018)

Sorry to Bother You (2018)

Robin Williams: Come Inside My Mind (2018)

The Happytime Murders (2018)
Incoming search terms:
Eighth Grade 2018 Watch Online, Watch Eighth Grade 2018 Online Free netflix, film Eighth Grade 2018 streaming, watch Eighth Grade movie now, watch Eighth Grade film online now, Watch Eighth Grade 2018 Online Free hulu, watch full Eighth Grade 2018 movie online, live streaming film Eighth Grade online, download Eighth Grade movie now, Watch Eighth Grade 2018 Online Free Putlocker, Watch Eighth Grade 2018 Online 123movie, Watch Eighth Grade 2018 Online Free megashare, film Eighth Grade 2018 trailer, Watch Eighth Grade 2018 Online Free 123movie, Watch Eighth Grade 2018 Online Free, Watch Eighth Grade 2018 Online Putlocker, film Eighth Grade 2018 download, live streaming movie Eighth Grade online, Streaming Eighth Grade 2018 For Free Online, Watch Eighth Grade 2018 Online Megashare, Eighth Grade movie download, Watch Eighth Grade 2018 For Free online, watch movie Eighth Grade 2018 now, Watch Eighth Grade 2018 Online Free Viooz, download movie Eighth Grade, streaming Eighth Grade movie, Watch Eighth Grade 2018 Online Viooz, streaming film Eighth Grade, watch full film Eighth Grade 2018, Watch Eighth Grade 2018 Online 123movies, film Eighth Grade online, live streaming film Eighth Grade, Streaming Eighth Grade 2018 Online Free Megashare.
Jun
22

Watch Full Movie Online Three Identical Strangers (2018)

Download and Watch Movie Three Identical Strangers (2018)

Three Identical Strangers

Released |Duration : 1 hours 36 minutes

7.6

DIRECTED BY : Tim Wardle.

PRODUCED BY : Grace Hughes-Hallett, Becky Read.

GENRE : Drama, Documentary.

VIDEO : 720p.

LANGUAGE : English.

MORE INFO

COUNTRY : United Kingdom.

PRODUCTION BY : Channel 4 Television, RAW.

PLOT SUMMARY

Movie ‘Three Identical Strangers’ was released in June 29, 2018 in genre Drama. Tim Wardle was directed this movie This movie tell story about New York, 1980: three complete strangers accidentally discover that they’re identical triplets, separated at birth. The 19-year-olds’ joyous reunion catapults them to international fame, but also unlocks an extraordinary and disturbing secret that goes beyond their own lives – and could transform our understanding of human nature forever.

CAST
YOU MAY ALSO LIKE

Juliet, Naked (2018)

Hearts Beat Loud (2018)

Puzzle (2018)

Blindspotting (2018)

Eighth Grade (2018)

Won’t You Be My Neighbor? (2018)

The Seagull (2018)

Whitney (2018)

Leave No Trace (2018)

Chappaquiddick (2018)
Incoming search terms:
Watch Three Identical Strangers 2018 Online Megashare, live streaming movie Three Identical Strangers 2018 online, watch full Three Identical Strangers film online, Three Identical Strangers 2018 movie, Watch Three Identical Strangers 2018 Online 123movie, Watch Three Identical Strangers 2018 Online Free hulu, download Three Identical Strangers 2018 movie, Three Identical Strangers 2018 Watch Online, watch Three Identical Strangers 2018 film now, Watch Three Identical Strangers 2018 Online 123movies, Watch Three Identical Strangers 2018 For Free online, Watch Three Identical Strangers 2018 Online Free netflix, Streaming Three Identical Strangers 2018 Online Free Megashare, Three Identical Strangers live streaming film, trailer film Three Identical Strangers 2018, Watch Three Identical Strangers 2018 Online Free 123movie, Watch Three Identical Strangers 2018 Online Free Putlocker, watch full Three Identical Strangers film, Streaming Three Identical Strangers 2018 For Free Online, watch full movie Three Identical Strangers online, Three Identical Strangers movie trailer, download Three Identical Strangers 2018 movie now, Watch Three Identical Strangers 2018 Online Free megashare, Watch Three Identical Strangers 2018 Online Putlocker, Watch Three Identical Strangers 2018 Online Free, Watch Three Identical Strangers 2018 Online Viooz, streaming movie Three Identical Strangers 2018, Three Identical Strangers 2018 streaming, download movie Three Identical Strangers now, Watch Three Identical Strangers 2018 Online Free Viooz, film Three Identical Strangers 2018 online.
Jun
20

Watch Full Movie Puzzle (2018)

Watch Full Movie Puzzle (2018)

Puzzle

Released |Duration : 1 hours 43 minutes

7.3

DIRECTED BY : Marc Turtletaub.

PRODUCED BY : Wren Arthur, Peter Saraf.

GENRE : Drama.

VIDEO : 720p.

LANGUAGE : English.

MORE INFO

COUNTRY : United States of America.

PRODUCTION BY : Big Beach, Olive Productions.

PLOT SUMMARY

Movie ‘Puzzle’ was released in July 27, 2018 in genre Drama. Marc Turtletaub was directed this movie and starring by Kelly Macdonald. This movie tell story about A woman with a talent for jigsaw puzzles partners with a charming stranger for a puzzle tournament.

CAST
YOU MAY ALSO LIKE

Three Identical Strangers (2018)
Incoming search terms:
watch Puzzle 2018 movie now, Streaming Puzzle 2018 Online Free Megashare, Watch Puzzle 2018 Online Viooz, watch full Puzzle movie, Watch Puzzle 2018 Online Megashare, Puzzle 2018 movie trailer, trailer film Puzzle, streaming Puzzle film, film Puzzle online streaming, Puzzle 2018 Watch Online, Watch Puzzle 2018 Online 123movies, Watch Puzzle 2018 Online Putlocker, Puzzle 2018 movie download, Watch Puzzle 2018 For Free online, Watch Puzzle 2018 Online Free hulu, download movie Puzzle, streaming Puzzle 2018, Watch Puzzle 2018 Online Free netflix, download Puzzle 2018 movie, Watch Puzzle 2018 Online Free Viooz, Watch Puzzle 2018 Online Free 123movie, Puzzle movie streaming, streaming film Puzzle 2018, film Puzzle 2018 trailer, Puzzle 2018 film download, Watch Puzzle 2018 Online Free, Watch Puzzle 2018 Online Free Putlocker, film Puzzle 2018 download, Watch Puzzle 2018 Online Free megashare, Streaming Puzzle 2018 For Free Online, Watch Puzzle 2018 Online 123movie, movie Puzzle streaming, download film Puzzle 2018 now.
Jun
19

Watch Full Movie Won’t You Be My Neighbor? (2018)

Streaming Movie Won't You Be My Neighbor? (2018) Online

Won’t You Be My Neighbor?

Released |Duration : 1 hours 33 minutes

8.8

DIRECTED BY : Morgan Neville.

PRODUCED BY : Caryn Capotosto, Morgan Neville.

GENRE : Drama, Documentary.

VIDEO : 720p.

LANGUAGE : English.

MORE INFO

COUNTRY : United States of America.

PRODUCTION BY : Tremolo Productions, Impact Partners, Focus Features.

PLOT SUMMARY

Movie ‘Won’t You Be My Neighbor?’ was released in June 8, 2018 in genre Drama. Morgan Neville was directed this movie and starring by Fred Rogers. This movie tell story about Fred Rogers used puppets and play to explore complex social issues: race, disability, equality and tragedy, helping form the American concept of childhood. He spoke directly to children and they responded enthusiastically. Yet today, his impact is unclear. Have we lived up to Fred’s ideal of good neighbors?

CAST
YOU MAY ALSO LIKE

Three Identical Strangers (2018)

RBG (2018)

Hearts Beat Loud (2018)

Eighth Grade (2018)

Support the Girls (2018)

Leave No Trace (2018)

Sorry to Bother You (2018)

Chappaquiddick (2018)

Robin Williams: Come Inside My Mind (2018)

Love on Delivery (1994)

Arrambam (2013)

American Animals (2018)

Duck Butter (2018)

Crazy Rich Asians (2018)

Film Stars Don’t Die in Liverpool (2017)

Tour de Pharmacy (2017)

The American Astronaut (2001)
Incoming search terms:
Won’t You Be My Neighbor? 2018 film download, Watch Won’t You Be My Neighbor? 2018 Online 123movies, film Won’t You Be My Neighbor? trailer, Streaming Won’t You Be My Neighbor? 2018 Online Free Megashare, film Won’t You Be My Neighbor? 2018, Watch Won’t You Be My Neighbor? 2018 Online Viooz, Watch Won’t You Be My Neighbor? 2018 Online Free megashare, film Won’t You Be My Neighbor? online, Watch Won’t You Be My Neighbor? 2018 Online Free netflix, Won’t You Be My Neighbor? 2018 movie trailer, Won’t You Be My Neighbor? 2018 movie, watch full film Won’t You Be My Neighbor?, download movie Won’t You Be My Neighbor?, live streaming film Won’t You Be My Neighbor? online, Watch Won’t You Be My Neighbor? 2018 For Free online, Watch Won’t You Be My Neighbor? 2018 Online Free Viooz, Watch Won’t You Be My Neighbor? 2018 Online Megashare, Watch Won’t You Be My Neighbor? 2018 Online Putlocker, film Won’t You Be My Neighbor? 2018 online streaming, Watch Won’t You Be My Neighbor? 2018 Online Free, watch Won’t You Be My Neighbor? film online now, Watch Won’t You Be My Neighbor? 2018 Online Free hulu, live streaming movie Won’t You Be My Neighbor? online, movie Won’t You Be My Neighbor?, Watch Won’t You Be My Neighbor? 2018 Online Free 123movie, Won’t You Be My Neighbor? 2018 Watch Online, streaming film Won’t You Be My Neighbor?, Streaming Won’t You Be My Neighbor? 2018 For Free Online, watch full movie Won’t You Be My Neighbor? 2018 online, Watch Won’t You Be My Neighbor? 2018 Online Free Putlocker, movie Won’t You Be My Neighbor? 2018 download, movie Won’t You Be My Neighbor? 2018 trailer, Watch Won’t You Be My Neighbor? 2018 Online 123movie.
Jun
06

Kubernetes Tips #1: security authn/authz for etcd

According to the CIS `–kubelet-client-certificate` and `–kubelet-client-key` arguments: “By default, certificate-based kublet authentication is not set.” The requests from the apiserver are treated anonymously.

Without those, the API server makes anonymous requests to the kubelet to do things like pod exec and logs requests. If that works, that means the kubelet has not enabled any authn/authz protections and anyone with network visibility to it can make those same exec/logs requests against it.

The above flags you want those on the API server, you also really want `–anonymous-auth=false` and `–authorization-mode=Webhook` on the Kubelet to enable authn/authz.

Thanks to Jordan Liggitt and Brad Geesaman

May
23

Nutanix Calm Blueprint for Auto Scaling Compute Resources for Cloudera

Adding additional compute resources by first looking at seasonal trending data from Prism Central. Auto scaling is done with using Nutanix Calm.

Save the below code as a json file.
cdh_parcel.version:\n cdh_parcel = p\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" downloaded\"\n\n# distribute the parcel\nprint \"Starting parcel distribution. This might take a while.\"\ncmd = cdh_parcel.start_distribution()\nif cmd.success != True:\n print \"Parcel distribution failed!\"\n exit(0)\n\nprint 'wait 4 min'\n# make sure the distribution finishes\n#while cdh_parcel.stage != \"DISTRIBUTED\":\nsleep(200)\n# cdh_parcel = get_parcel(api, cdh_parcel.product, '5.13.3-1.cdh5.13.3.p0.2', cluster_name)\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" distributed\"\n\n# activate the parcel\ncmd = cdh_parcel.activate()\nif cmd.success != True:\n print \"Parcel activation failed!\"\n exit(0)\n\n# make sure the activation finishes\n#while cdh_parcel.stage != \"ACTIVATED\":\n# cdh_parcel = get_parcel(api, cdh_parcel.product, '5.13.3-1.cdh5.13.3.p0.2', cluster_name)\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" activated\"\n\n\nyarn = cluster.get_service('yarn')\nprint yarn.name\nhostsid = api.get_all_hosts()\n#range = len(hostsid)\n#print 'range: ' + range\n\nfor current in hostsid:\n if current.rackId == '/default/default':\n print 'host name to add' + current.hostname\n currentshort1 = current.hostname\n currentshort = currentshort1.split(\".\", 1)\n short = currentshort[0]\n print short\n yarn.create_role(short, 'NODEMANAGER', current.hostId)\n\ncluster.restart(restart_only_stale_services=True, redeploy_client_configuration=True)\n\nexit(0)", "script_type": "sh", "type": "", "command_line_args": "", "login_credential_local_reference": {"kind": "app_credential", "name": "go", "uuid": "f356d2b6-2fac-453c-84ad-d91bc21bb1ba"}}, "timeout_secs": "", "type": "EXEC", "variable_list": [], "uuid": "b24dd948-e65d-2c1e-52d8-c4d21d615274"}], "description": "", "name": "7da2879a_runbook_cloned_1", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "6405be68_dag", "uuid": "7ec268af-4e53-3c55-930a-740501d41cfb"}, "message_list": [], "variable_list": [], "uuid": "2363d280-af23-b97a-557f-1e6a3d156fbb"}, "type": "", "uninstall_runbook": {"task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "de4520ca_dag", "state": "ACTIVE", "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "uuid": "aabae04b-08bb-466e-76a2-1fcfc3c816cd"}], "description": "", "name": "339b443d_runbook_cloned_1", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "de4520ca_dag", "uuid": "aabae04b-08bb-466e-76a2-1fcfc3c816cd"}, "message_list": [], "variable_list": [], "uuid": "ff185ae5-bc26-095b-6840-9fc957638621"}}, "timeout_secs": "", "type": "CUSTOM_PACKAGE_INSTALL", "variable_list": [], "uuid": "47831e03-3fa0-4a8e-b26c-8244da30ab82"}], "description": "", "name": "SYS_GEN__Runbook_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "SYS_GEN__DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "078dca59-9b50-4ad8-b048-2ca148f8251e"}, "message_list": [], "variable_list": [], "uuid": "b81bf28e-424c-4daa-9beb-8ae9a62855ba"}, "message_list": [], "name": "action_install"}, {"description": "System action for creating an application", "type": "system", "uuid": "563a264b-ca8e-4279-ad98-96e4e8d77282", "state": "ACTIVE", "critical": true, "attrs": {}, "runbook": {"task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [{"kind": "app_task", "name": "SYS_GEN__install_CRb_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "d4857a2b-32f6-471d-9e05-295df9e45c87"}, {"kind": "app_task", "name": "SYS_GEN__create_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "55697484-6734-4bdd-afde-75e8c171697e"}, {"kind": "app_task", "name": "SYS_GEN__start_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "d5751cd2-f72a-4f35-9fd6-104079471e54"}], "name": "SYS_GEN__Composite_DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "attrs": {"edges": [{"from_task_reference": {"kind": "app_task", "name": "SYS_GEN__create_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "55697484-6734-4bdd-afde-75e8c171697e"}, "edge_type": "inherent", "type": "", "uuid": "873c853d-d849-46a7-9344-625a6b9c0898", "to_task_reference": {"kind": "app_task", "name": "SYS_GEN__start_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "d5751cd2-f72a-4f35-9fd6-104079471e54"}}, {"from_task_reference": {"kind": "app_task", "name": "SYS_GEN__install_CRb_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "d4857a2b-32f6-471d-9e05-295df9e45c87"}, "edge_type": "inherent", "type": "", "uuid": "d316c8f7-435c-4b1c-ad0c-7b1d02696dcd", "to_task_reference": {"kind": "app_task", "name": "SYS_GEN__create_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "55697484-6734-4bdd-afde-75e8c171697e"}}], "type": "DAG"}, "timeout_secs": "", "type": "DAG", "variable_list": [], "uuid": "dcc6c9a0-ef16-406c-8960-b313800452b3"}, {"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "SYS_GEN__install_CRb_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "attrs": {"type": "CALL_RUNBOOK", "inarg_list": [], "runbook_reference": {"kind": "app_runbook", "name": "SYS_GEN__Runbook_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "b81bf28e-424c-4daa-9beb-8ae9a62855ba"}}, "timeout_secs": "", "type": "CALL_RUNBOOK", "variable_list": [], "uuid": "d4857a2b-32f6-471d-9e05-295df9e45c87"}, {"target_any_local_reference": {"kind": "app_service", "name": "code", "uuid": "0afc9748-88f7-8e8c-f7fe-b2b2cd6669e1"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "SYS_GEN__create_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "state": "ACTIVE", "attrs": {"type": "CALL_RUNBOOK", "inarg_list": [], "runbook_reference": {"kind": "app_runbook", "name": "eba78c76_runbook_cloned_1", "uuid": "e3ec95e5-6ede-c168-b629-600d771f5803"}}, "timeout_secs": "", "type": "CALL_RUNBOOK", "variable_list": [], "uuid": "55697484-6734-4bdd-afde-75e8c171697e"}, {"target_any_local_reference": {"kind": "app_service", "name": "code", "uuid": "0afc9748-88f7-8e8c-f7fe-b2b2cd6669e1"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "SYS_GEN__start_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "state": "ACTIVE", "attrs": {"type": "CALL_RUNBOOK", "inarg_list": [], "runbook_reference": {"kind": "app_runbook", "name": "3cedb317_runbook_cloned_1", "uuid": "aeedc907-4495-18e4-e7aa-93b781b90737"}}, "timeout_secs": "", "type": "CALL_RUNBOOK", "variable_list": [], "uuid": "d5751cd2-f72a-4f35-9fd6-104079471e54"}], "description": "", "name": "SYS_GEN__Runbook_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "SYS_GEN__Composite_DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "dcc6c9a0-ef16-406c-8960-b313800452b3"}, "message_list": [], "variable_list": [], "uuid": "daf9342b-98d9-4877-aee9-b322ed207462"}, "message_list": [], "name": "action_create"}, {"description": "System action for uninstalling an application", "type": "system", "uuid": "3255d19b-f2af-4d1f-a517-f91bf14bdc93", "state": "ACTIVE", "critical": true, "attrs": {}, "runbook": {"task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [{"kind": "app_task", "name": "PE_Uninstall_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "aa9bdd7f-4d40-4d9c-af4d-13091c066f70"}], "name": "SYS_GEN__DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "attrs": {"edges": [], "type": "DAG"}, "timeout_secs": "", "type": "DAG", "variable_list": [], "uuid": "92cd3b4b-fc1a-4dc3-9f17-6a5de9a2473e"}, {"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "PE_Uninstall_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "attrs": {"install_runbook": {"task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [{"kind": "app_task", "name": "PackageInstallTask", "uuid": "b24dd948-e65d-2c1e-52d8-c4d21d615274"}], "name": "6405be68_dag", "state": "ACTIVE", "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "uuid": "7ec268af-4e53-3c55-930a-740501d41cfb"}, {"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "PackageInstallTask", "state": "ACTIVE", "attrs": {"exit_status": [], "script": "#!/usr/bin/env python\nfrom cm_api.api_client import ApiResource\nfrom cm_api.endpoints.clusters import ApiCluster\nfrom cm_api.endpoints.clusters import create_cluster\nfrom cm_api.endpoints.parcels import ApiParcel\nfrom cm_api.endpoints.parcels import get_parcel\nfrom cm_api.endpoints.cms import ClouderaManager\nfrom cm_api.endpoints.services import ApiService, ApiServiceSetupInfo\nfrom cm_api.endpoints.services import create_service\nfrom cm_api.endpoints.types import ApiCommand, ApiRoleConfigGroupRef\nfrom cm_api.endpoints.role_config_groups import get_role_config_group\nfrom cm_api.endpoints.role_config_groups import ApiRoleConfigGroup\nfrom cm_api.endpoints.roles import ApiRole\nfrom time import sleep\n\nhost_username = 'root'\ncm_repo_url = None\ncdh_version = \"CDH5\" # also valid: \"CDH4\"\ncdh_version_number = \"5\"\n#240\nsleep(240)\n\nhostsIP = [ ]\nhostNames = [ ]\nhostNamesLong = [ ]\nthostNames = [ ]\nthostNames = \"@@{compute.name}@@\"\n#hostsIP = thostsIP.split(,)\nhostNames = thostNames.split(\",\")\n\n#for name in hostName:\n # hostNamesLong = hostName.append(name + '.rf9.local')\n\nfor name in hostNames:\n hostNamesLong.append(name + '.rf9.local')\n print hostNamesLong\n \nprint \"@@{code.cmip}@@\"\nprint \"@@{code.cmPassword}@@\"\n\napi = ApiResource(\"@@{code.cmip}@@\", '7180', \"@@{code.cmAdmin}@@\", \"@@{code.cmPassword}@@\", version=\"@@{code.APIversion}@@\")\n\n#get the CM instance\ncm = api.get_cluster(\"@@{code.clusterName}@@\")\ncm = ClouderaManager(api)\n\n\ncmd = cm.host_install(\"@@{code.hostAdmin}@@\", hostNamesLong, password=\"@@{code.hostPassword}@@\", cm_repo_url=cm_repo_url)\nprint \"Installing hosts. This might take a while.\"\nwhile cmd.success == None:\n sleep(15)\n cmd = cmd.fetch()\n\nif cmd.success != True:\n print \"cm_host_install failed: \" + cmd.resultMessage\n# exit(0)\nprint \"cm_host_install succeeded\"\n\ncluster = api.get_cluster(\"@@{code.clusterName}@@\")\n\nhostsadded = cluster.add_hosts(hostNamesLong)\n\nparcels_list = []\n# get and list all available parcels\nprint \"Available parcels:\"\nfor p in cluster.get_all_parcels():\n print p.version\n if p.version.startswith(\"@@{code.cmPackage}@@\") and p.product == \"CDH\":\n parcels_list.append(p)\n\nif len(parcels_list) == 0:\n print \"No \"\n print cdh_version\n print \" parcel found!\"\n exit(0)\n\ncdh_parcel = parcels_list[0]\n\nfor p in parcels_list:\n if p.version > cdh_parcel.version:\n cdh_parcel = p\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" downloaded\"\n\n# distribute the parcel\nprint \"Starting parcel distribution. This might take a while.\"\ncmd = cdh_parcel.start_distribution()\nif cmd.success != True:\n print \"Parcel distribution failed!\"\n exit(0)\n\nprint 'wait 4 min'\n# make sure the distribution finishes\n#while cdh_parcel.stage != \"DISTRIBUTED\":\nsleep(200)\n# cdh_parcel = get_parcel(api, cdh_parcel.product, '5.13.3-1.cdh5.13.3.p0.2', cluster_name)\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" distributed\"\n\n# activate the parcel\ncmd = cdh_parcel.activate()\nif cmd.success != True:\n print \"Parcel activation failed!\"\n exit(0)\n\n# make sure the activation finishes\n#while cdh_parcel.stage != \"ACTIVATED\":\n# cdh_parcel = get_parcel(api, cdh_parcel.product, '5.13.3-1.cdh5.13.3.p0.2', cluster_name)\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" activated\"\n\n\nyarn = cluster.get_service('yarn')\nprint yarn.name\nhostsid = api.get_all_hosts()\n#range = len(hostsid)\n#print 'range: ' + range\n\nfor current in hostsid:\n if current.rackId == '/default/default':\n print 'host name to add' + current.hostname\n currentshort1 = current.hostname\n currentshort = currentshort1.split(\".\", 1)\n short = currentshort[0]\n print short\n yarn.create_role(short, 'NODEMANAGER', current.hostId)\n\ncluster.restart(restart_only_stale_services=True, redeploy_client_configuration=True)\n\nexit(0)", "script_type": "sh", "type": "", "command_line_args": "", "login_credential_local_reference": {"kind": "app_credential", "name": "go", "uuid": "f356d2b6-2fac-453c-84ad-d91bc21bb1ba"}}, "timeout_secs": "", "type": "EXEC", "variable_list": [], "uuid": "b24dd948-e65d-2c1e-52d8-c4d21d615274"}], "description": "", "name": "7da2879a_runbook_cloned_1", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "6405be68_dag", "uuid": "7ec268af-4e53-3c55-930a-740501d41cfb"}, "message_list": [], "variable_list": [], "uuid": "2363d280-af23-b97a-557f-1e6a3d156fbb"}, "type": "", "uninstall_runbook": {"task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "de4520ca_dag", "state": "ACTIVE", "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "uuid": "aabae04b-08bb-466e-76a2-1fcfc3c816cd"}], "description": "", "name": "339b443d_runbook_cloned_1", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "de4520ca_dag", "uuid": "aabae04b-08bb-466e-76a2-1fcfc3c816cd"}, "message_list": [], "variable_list": [], "uuid": "ff185ae5-bc26-095b-6840-9fc957638621"}}, "timeout_secs": "", "type": "CUSTOM_PACKAGE_UNINSTALL", "variable_list": [], "uuid": "aa9bdd7f-4d40-4d9c-af4d-13091c066f70"}], "description": "", "name": "SYS_GEN__Runbook_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "SYS_GEN__DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "92cd3b4b-fc1a-4dc3-9f17-6a5de9a2473e"}, "message_list": [], "variable_list": [], "uuid": "3efda7af-c2c5-4527-91b8-0c58ae037827"}, "message_list": [], "name": "action_uninstall"}, {"description": "System action for deleting an application. Deletes physical machines as well", "type": "system", "uuid": "7ad1b2bf-b87c-4d3d-8da5-33abeb3cb757", "state": "ACTIVE", "critical": true, "attrs": {}, "runbook": {"task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [{"kind": "app_task", "name": "SYS_GEN__stop_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "5b2b1a62-4e83-4d1b-934b-862d89fc58f9"}, {"kind": "app_task", "name": "SYS_GEN__delete_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "2ce000b8-1296-4f5d-a8ae-8da96433a1cf"}, {"kind": "app_task", "name": "SYS_GEN__uninstall_CRb_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "1a05ced5-575f-4daf-ae7c-033403a0e77d"}], "name": "SYS_GEN__Composite_DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "attrs": {"edges": [{"from_task_reference": {"kind": "app_task", "name": "SYS_GEN__stop_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "5b2b1a62-4e83-4d1b-934b-862d89fc58f9"}, "edge_type": "inherent", "type": "", "uuid": "60c3c99d-672f-49af-b994-89bd9f92909e", "to_task_reference": {"kind": "app_task", "name": "SYS_GEN__delete_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "2ce000b8-1296-4f5d-a8ae-8da96433a1cf"}}, {"from_task_reference": {"kind": "app_task", "name": "SYS_GEN__delete_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "2ce000b8-1296-4f5d-a8ae-8da96433a1cf"}, "edge_type": "inherent", "type": "", "uuid": "be945022-5672-4d55-9a03-54584bb4b48f", "to_task_reference": {"kind": "app_task", "name": "SYS_GEN__uninstall_CRb_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "1a05ced5-575f-4daf-ae7c-033403a0e77d"}}], "type": "DAG"}, "timeout_secs": "", "type": "DAG", "variable_list": [], "uuid": "24022115-efdb-4ecf-b9b2-6275a9944739"}, {"target_any_local_reference": {"kind": "app_service", "name": "code", "uuid": "0afc9748-88f7-8e8c-f7fe-b2b2cd6669e1"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "SYS_GEN__stop_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "state": "ACTIVE", "attrs": {"type": "CALL_RUNBOOK", "inarg_list": [], "runbook_reference": {"kind": "app_runbook", "name": "5be55dea_runbook_cloned_1", "uuid": "aec97efe-ee30-0743-f90f-192698db865c"}}, "timeout_secs": "", "type": "CALL_RUNBOOK", "variable_list": [], "uuid": "5b2b1a62-4e83-4d1b-934b-862d89fc58f9"}, {"target_any_local_reference": {"kind": "app_service", "name": "code", "uuid": "0afc9748-88f7-8e8c-f7fe-b2b2cd6669e1"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "SYS_GEN__delete_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "state": "ACTIVE", "attrs": {"type": "CALL_RUNBOOK", "inarg_list": [], "runbook_reference": {"kind": "app_runbook", "name": "740b4861_runbook_cloned_1", "uuid": "3b9eb309-30d3-a2ae-137b-9d1552ea6038"}}, "timeout_secs": "", "type": "CALL_RUNBOOK", "variable_list": [], "uuid": "2ce000b8-1296-4f5d-a8ae-8da96433a1cf"}, {"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "SYS_GEN__uninstall_CRb_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "attrs": {"type": "CALL_RUNBOOK", "inarg_list": [], "runbook_reference": {"kind": "app_runbook", "name": "SYS_GEN__Runbook_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "3efda7af-c2c5-4527-91b8-0c58ae037827"}}, "timeout_secs": "", "type": "CALL_RUNBOOK", "variable_list": [], "uuid": "1a05ced5-575f-4daf-ae7c-033403a0e77d"}], "description": "", "name": "SYS_GEN__Runbook_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "SYS_GEN__Composite_DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "24022115-efdb-4ecf-b9b2-6275a9944739"}, "message_list": [], "variable_list": [], "uuid": "13878dbf-d8a6-46ae-b2ba-91b2d94c80b6"}, "message_list": [], "name": "action_delete"}, {"description": "System action for deleting an application. Does not delete physical machines", "type": "system", "uuid": "514bcd42-76cc-4588-aaca-d8c090d2b394", "state": "ACTIVE", "critical": true, "attrs": {}, "runbook": {"task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [{"kind": "app_task", "name": "SYS_GEN__soft_delete_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "4378066f-61a2-455f-bac8-42fded9ad756"}, {"kind": "app_task", "name": "SYS_GEN__Package_Element_Delete_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "c3dcc740-7e1c-40b9-9c5f-80243f049090"}], "name": "SYS_GEN__Composite_DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "attrs": {"edges": [{"from_task_reference": {"kind": "app_task", "name": "SYS_GEN__soft_delete_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "4378066f-61a2-455f-bac8-42fded9ad756"}, "edge_type": "inherent", "type": "", "uuid": "eaa03831-dedd-430b-a855-b2f31ce3a575", "to_task_reference": {"kind": "app_task", "name": "SYS_GEN__Package_Element_Delete_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "c3dcc740-7e1c-40b9-9c5f-80243f049090"}}], "type": "DAG"}, "timeout_secs": "", "type": "DAG", "variable_list": [], "uuid": "b0c7ab87-e166-4b64-8e34-ecff50898741"}, {"target_any_local_reference": {"kind": "app_service", "name": "code", "uuid": "0afc9748-88f7-8e8c-f7fe-b2b2cd6669e1"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "SYS_GEN__soft_delete_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "state": "ACTIVE", "attrs": {"type": "CALL_RUNBOOK", "inarg_list": [], "runbook_reference": {"kind": "app_runbook", "name": "SYS_GEN__Runbook_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "d9c0f039-0740-41ee-9d53-d5846fb8aa33"}}, "timeout_secs": "", "type": "CALL_RUNBOOK", "variable_list": [], "uuid": "4378066f-61a2-455f-bac8-42fded9ad756"}, {"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "SYS_GEN__Package_Element_Delete_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "attrs": {"type": ""}, "timeout_secs": "", "type": "SOFT_DELETE_ELEMENT", "variable_list": [], "uuid": "c3dcc740-7e1c-40b9-9c5f-80243f049090"}], "description": "", "name": "SYS_GEN__Runbook_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "SYS_GEN__Composite_DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "b0c7ab87-e166-4b64-8e34-ecff50898741"}, "message_list": [], "variable_list": [], "uuid": "a33c5528-ee5d-45c1-a762-1130af869bfd"}, "message_list": [], "name": "action_soft_delete"}, {"description": "System action for starting an application", "type": "system", "uuid": "a85a6591-bc55-4b22-9057-dc49a156d6d0", "state": "ACTIVE", "critical": true, "attrs": {}, "runbook": {"task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [{"kind": "app_task", "name": "SYS_GEN__start_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "4fbf8a01-298d-4363-8968-6f4b034ee440"}], "name": "SYS_GEN__Composite_DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "attrs": {"edges": [], "type": "DAG"}, "timeout_secs": "", "type": "DAG", "variable_list": [], "uuid": "c340dcbc-2937-40b0-82a9-e82c9ea49f06"}, {"target_any_local_reference": {"kind": "app_service", "name": "code", "uuid": "0afc9748-88f7-8e8c-f7fe-b2b2cd6669e1"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "SYS_GEN__start_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "state": "ACTIVE", "attrs": {"type": "CALL_RUNBOOK", "inarg_list": [], "runbook_reference": {"kind": "app_runbook", "name": "3cedb317_runbook_cloned_1", "uuid": "aeedc907-4495-18e4-e7aa-93b781b90737"}}, "timeout_secs": "", "type": "CALL_RUNBOOK", "variable_list": [], "uuid": "4fbf8a01-298d-4363-8968-6f4b034ee440"}], "description": "", "name": "SYS_GEN__Runbook_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "SYS_GEN__Composite_DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "c340dcbc-2937-40b0-82a9-e82c9ea49f06"}, "message_list": [], "variable_list": [], "uuid": "12813311-3bf3-486f-b59a-ec1087c2f54d"}, "message_list": [], "name": "action_start"}, {"description": "System action for stopping an application", "type": "system", "uuid": "cf8d0527-c638-4d40-8947-a8bf1cb1d051", "state": "ACTIVE", "critical": true, "attrs": {}, "runbook": {"task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [{"kind": "app_task", "name": "SYS_GEN__stop_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "uuid": "9626db53-15f7-4f28-83b0-70061870f14f"}], "name": "SYS_GEN__Composite_DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "attrs": {"edges": [], "type": "DAG"}, "timeout_secs": "", "type": "DAG", "variable_list": [], "uuid": "fd0d81b5-563f-46bc-b001-b3e967bf45a0"}, {"target_any_local_reference": {"kind": "app_service", "name": "code", "uuid": "0afc9748-88f7-8e8c-f7fe-b2b2cd6669e1"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "SYS_GEN__stop_CRb_Service_0afc9748_88f7_8e8c_f7fe_b2b2cd6669e1", "state": "ACTIVE", "attrs": {"type": "CALL_RUNBOOK", "inarg_list": [], "runbook_reference": {"kind": "app_runbook", "name": "5be55dea_runbook_cloned_1", "uuid": "aec97efe-ee30-0743-f90f-192698db865c"}}, "timeout_secs": "", "type": "CALL_RUNBOOK", "variable_list": [], "uuid": "9626db53-15f7-4f28-83b0-70061870f14f"}], "description": "", "name": "SYS_GEN__Runbook_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "SYS_GEN__Composite_DAG_Package_44bbdab6_b71e_8989_d19b_aeb8c940122c", "uuid": "fd0d81b5-563f-46bc-b001-b3e967bf45a0"}, "message_list": [], "variable_list": [], "uuid": "6715e54e-21f8-4206-9d27-bb4518c0a012"}, "message_list": [], "name": "action_stop"}], "type": "DEB", "service_local_reference_list": [{"kind": "app_service", "name": "code", "uuid": "0afc9748-88f7-8e8c-f7fe-b2b2cd6669e1"}], "name": "cloudera", "state": "ACTIVE", "version": "", "editables": {}, "message_list": [], "options": {"install_runbook": {"task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [{"kind": "app_task", "name": "PackageInstallTask", "uuid": "b24dd948-e65d-2c1e-52d8-c4d21d615274"}], "name": "6405be68_dag", "state": "ACTIVE", "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "uuid": "7ec268af-4e53-3c55-930a-740501d41cfb"}, {"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "PackageInstallTask", "state": "ACTIVE", "attrs": {"exit_status": [], "script": "#!/usr/bin/env python\nfrom cm_api.api_client import ApiResource\nfrom cm_api.endpoints.clusters import ApiCluster\nfrom cm_api.endpoints.clusters import create_cluster\nfrom cm_api.endpoints.parcels import ApiParcel\nfrom cm_api.endpoints.parcels import get_parcel\nfrom cm_api.endpoints.cms import ClouderaManager\nfrom cm_api.endpoints.services import ApiService, ApiServiceSetupInfo\nfrom cm_api.endpoints.services import create_service\nfrom cm_api.endpoints.types import ApiCommand, ApiRoleConfigGroupRef\nfrom cm_api.endpoints.role_config_groups import get_role_config_group\nfrom cm_api.endpoints.role_config_groups import ApiRoleConfigGroup\nfrom cm_api.endpoints.roles import ApiRole\nfrom time import sleep\n\nhost_username = 'root'\ncm_repo_url = None\ncdh_version = \"CDH5\" # also valid: \"CDH4\"\ncdh_version_number = \"5\"\n#240\nsleep(240)\n\nhostsIP = [ ]\nhostNames = [ ]\nhostNamesLong = [ ]\nthostNames = [ ]\nthostNames = \"@@{compute.name}@@\"\n#hostsIP = thostsIP.split(,)\nhostNames = thostNames.split(\",\")\n\n#for name in hostName:\n # hostNamesLong = hostName.append(name + '.rf9.local')\n\nfor name in hostNames:\n hostNamesLong.append(name + '.rf9.local')\n print hostNamesLong\n \nprint \"@@{code.cmip}@@\"\nprint \"@@{code.cmPassword}@@\"\n\napi = ApiResource(\"@@{code.cmip}@@\", '7180', \"@@{code.cmAdmin}@@\", \"@@{code.cmPassword}@@\", version=\"@@{code.APIversion}@@\")\n\n#get the CM instance\ncm = api.get_cluster(\"@@{code.clusterName}@@\")\ncm = ClouderaManager(api)\n\n\ncmd = cm.host_install(\"@@{code.hostAdmin}@@\", hostNamesLong, password=\"@@{code.hostPassword}@@\", cm_repo_url=cm_repo_url)\nprint \"Installing hosts. This might take a while.\"\nwhile cmd.success == None:\n sleep(15)\n cmd = cmd.fetch()\n\nif cmd.success != True:\n print \"cm_host_install failed: \" + cmd.resultMessage\n# exit(0)\nprint \"cm_host_install succeeded\"\n\ncluster = api.get_cluster(\"@@{code.clusterName}@@\")\n\nhostsadded = cluster.add_hosts(hostNamesLong)\n\nparcels_list = []\n# get and list all available parcels\nprint \"Available parcels:\"\nfor p in cluster.get_all_parcels():\n print p.version\n if p.version.startswith(\"@@{code.cmPackage}@@\") and p.product == \"CDH\":\n parcels_list.append(p)\n\nif len(parcels_list) == 0:\n print \"No \"\n print cdh_version\n print \" parcel found!\"\n exit(0)\n\ncdh_parcel = parcels_list[0]\n\nfor p in parcels_list:\n if p.version > cdh_parcel.version:\n cdh_parcel = p\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" downloaded\"\n\n# distribute the parcel\nprint \"Starting parcel distribution. This might take a while.\"\ncmd = cdh_parcel.start_distribution()\nif cmd.success != True:\n print \"Parcel distribution failed!\"\n exit(0)\n\nprint 'wait 4 min'\n# make sure the distribution finishes\n#while cdh_parcel.stage != \"DISTRIBUTED\":\nsleep(200)\n# cdh_parcel = get_parcel(api, cdh_parcel.product, '5.13.3-1.cdh5.13.3.p0.2', cluster_name)\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" distributed\"\n\n# activate the parcel\ncmd = cdh_parcel.activate()\nif cmd.success != True:\n print \"Parcel activation failed!\"\n exit(0)\n\n# make sure the activation finishes\n#while cdh_parcel.stage != \"ACTIVATED\":\n# cdh_parcel = get_parcel(api, cdh_parcel.product, '5.13.3-1.cdh5.13.3.p0.2', cluster_name)\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" activated\"\n\n\nyarn = cluster.get_service('yarn')\nprint yarn.name\nhostsid = api.get_all_hosts()\n#range = len(hostsid)\n#print 'range: ' + range\n\nfor current in hostsid:\n if current.rackId == '/default/default':\n print 'host name to add' + current.hostname\n currentshort1 = current.hostname\n currentshort = currentshort1.split(\".\", 1)\n short = currentshort[0]\n print short\n yarn.create_role(short, 'NODEMANAGER', current.hostId)\n\ncluster.restart(restart_only_stale_services=True, redeploy_client_configuration=True)\n\nexit(0)", "script_type": "sh", "type": "", "command_line_args": "", "login_credential_local_reference": {"kind": "app_credential", "name": "go", "uuid": "f356d2b6-2fac-453c-84ad-d91bc21bb1ba"}}, "timeout_secs": "", "type": "EXEC", "variable_list": [], "uuid": "b24dd948-e65d-2c1e-52d8-c4d21d615274"}], "description": "", "name": "7da2879a_runbook_cloned_1", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "6405be68_dag", "uuid": "7ec268af-4e53-3c55-930a-740501d41cfb"}, "message_list": [], "variable_list": [], "uuid": "2363d280-af23-b97a-557f-1e6a3d156fbb"}, "type": "", "uninstall_runbook": {"task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera", "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}, "description": "", "message_list": [], "child_tasks_local_reference_list": [], "name": "de4520ca_dag", "state": "ACTIVE", "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "uuid": "aabae04b-08bb-466e-76a2-1fcfc3c816cd"}], "description": "", "name": "339b443d_runbook_cloned_1", "state": "ACTIVE", "main_task_local_reference": {"kind": "app_task", "name": "de4520ca_dag", "uuid": "aabae04b-08bb-466e-76a2-1fcfc3c816cd"}, "message_list": [], "variable_list": [], "uuid": "ff185ae5-bc26-095b-6840-9fc957638621"}}, "variable_list": [], "uuid": "44bbdab6-b71e-8989-d19b-aeb8c940122c"}]}, "name": "computeexpand"}, "spec": {"description": "", "resources": {"service_definition_list": [{"singleton": false, "name": "compute", "action_list": [{"critical": false, "type": "system", "description": "System action for creating an application", "name": "action_create", "runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_service", "name": "compute"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "b3c287b5_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "b3c287b5_dag"}, "name": "eba78c76_runbook"}}, {"critical": false, "type": "system", "description": "System action for deleting an application. Deletes physical machines as well", "name": "action_delete", "runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_service", "name": "compute"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "1744848a_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "1744848a_dag"}, "name": "740b4861_runbook"}}, {"critical": false, "type": "system", "description": "System action for starting an application", "name": "action_start", "runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_service", "name": "compute"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "87c10021_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "87c10021_dag"}, "name": "3cedb317_runbook"}}, {"critical": false, "type": "system", "description": "System action for stopping an application", "name": "action_stop", "runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_service", "name": "compute"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "c68f8d5e_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "c68f8d5e_dag"}, "name": "5be55dea_runbook"}}, {"critical": false, "type": "system", "description": "System action for restarting an application", "name": "action_restart", "runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_service", "name": "compute"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "5869d3a7_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "5869d3a7_dag"}, "name": "4ebd0004_runbook"}}], "description": "", "port_list": [], "tier": "", "variable_list": [], "depends_on_list": []}, {"singleton": false, "name": "code", "action_list": [{"critical": false, "type": "system", "description": "System action for creating an application", "name": "action_create", "runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_service", "name": "code"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "b3c287b5_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "b3c287b5_dag"}, "name": "eba78c76_runbook_cloned_1"}}, {"critical": false, "type": "system", "description": "System action for deleting an application. Deletes physical machines as well", "name": "action_delete", "runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_service", "name": "code"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "1744848a_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "1744848a_dag"}, "name": "740b4861_runbook_cloned_1"}}, {"critical": false, "type": "system", "description": "System action for starting an application", "name": "action_start", "runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_service", "name": "code"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "87c10021_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "87c10021_dag"}, "name": "3cedb317_runbook_cloned_1"}}, {"critical": false, "type": "system", "description": "System action for stopping an application", "name": "action_stop", "runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_service", "name": "code"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "c68f8d5e_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "c68f8d5e_dag"}, "name": "5be55dea_runbook_cloned_1"}}, {"critical": false, "type": "system", "description": "System action for restarting an application", "name": "action_restart", "runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_service", "name": "code"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "5869d3a7_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "5869d3a7_dag"}, "name": "4ebd0004_runbook_cloned_1"}}], "description": "", "port_list": [], "tier": "", "variable_list": [{"val_type": "STRING", "description": "", "value": "admin", "label": "", "attrs": {"type": ""}, "type": "LOCAL", "name": "cmAdmin"}, {"val_type": "STRING", "description": "", "value": "10.15.80.180", "label": "", "attrs": {"type": ""}, "type": "LOCAL", "name": "cmip"}, {"val_type": "STRING", "description": "", "value": "", "label": "", "attrs": {"is_secret_modified": false, "secret_reference": {}, "type": ""}, "type": "SECRET", "name": "cmPassword"}, {"val_type": "STRING", "description": "", "value": "18", "label": "", "attrs": {"type": ""}, "type": "LOCAL", "name": "APIversion"}, {"val_type": "STRING", "description": "", "value": "Cluster 1", "label": "", "attrs": {"type": ""}, "type": "LOCAL", "name": "clusterName"}, {"val_type": "STRING", "description": "", "value": "5.13.3-1.cdh5.13.3", "label": "", "attrs": {"type": ""}, "type": "LOCAL", "name": "cmPackage"}, {"val_type": "STRING", "description": "", "value": "", "label": "", "attrs": {"is_secret_modified": false, "secret_reference": {}, "type": ""}, "type": "SECRET", "name": "hostPassword"}, {"val_type": "STRING", "description": "", "value": "root", "label": "", "attrs": {"type": ""}, "type": "LOCAL", "name": "hostAdmin"}], "depends_on_list": []}], "substrate_definition_list": [{"description": "", "action_list": [], "readiness_probe": {"connection_type": "SSH", "address": "@@{platform.status.resources.nic_list[0].ip_endpoint_list[0].ip}@@", "disable_readiness_probe": false, "timeout_secs": "60", "connection_port": 22}, "editables": {"create_spec": {"resources": {}}}, "os_type": "Linux", "type": "AHV_VM", "create_spec": {"backup_policy": null, "type": "", "name": "yarn@@{calm_application_name}@@-@@{calm_random}@@", "resources": {"hardware_clock_timezone": "", "type": "", "boot_config": null, "power_state": "ON", "guest_tools": null}, "availability_zone_reference": null}, "variable_list": [], "name": "yarn"}, {"description": "", "action_list": [], "readiness_probe": {"connection_type": "SSH", "address": "@@{platform.status.resources.nic_list[0].ip_endpoint_list[0].ip}@@", "disable_readiness_probe": false, "timeout_secs": "60", "connection_port": 22}, "editables": {"create_spec": {"resources": {}}}, "os_type": "Linux", "type": "AHV_VM", "create_spec": {"backup_policy": null, "type": "", "name": "run@@{calm_application_name}@@-@@{calm_random}@@", "resources": {"hardware_clock_timezone": "", "type": "", "boot_config": {"boot_device": {"type": "", "disk_address": {"adapter_type": "SCSI", "device_index": 0, "type": ""}}, "type": "", "mac_address": ""}, "power_state": "ON", "guest_tools": null}, "availability_zone_reference": null}, "variable_list": [], "name": "runner"}], "credential_definition_list": [{"username": "root", "secret": {"attrs": {"is_secret_modified": false, "secret_reference": {}}}, "type": "PASSWORD", "description": "", "name": "go"}], "package_definition_list": [{"description": "", "action_list": [], "service_local_reference_list": [{"kind": "app_service", "name": "compute"}], "version": "", "type": "DEB", "options": {"install_runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "deployCPUa"}, "description": "", "child_tasks_local_reference_list": [{"kind": "app_task", "name": "PackageInstallTask"}], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "6405be68_dag"}, {"target_any_local_reference": {"kind": "app_package", "name": "deployCPUa"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"exit_status": [], "script": "#!/usr/bin/env bash\n\nhostnamectl set-hostname @@{name}@@.rf9.local\n\nsystemctl restart network.service", "script_type": "sh", "type": "", "command_line_args": "", "login_credential_local_reference": {"kind": "app_credential", "name": "go"}}, "timeout_secs": "", "type": "EXEC", "variable_list": [], "name": "PackageInstallTask"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "6405be68_dag"}, "name": "7da2879a_runbook"}, "type": "", "uninstall_runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "deployCPUa"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "de4520ca_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "de4520ca_dag"}, "name": "339b443d_runbook"}}, "variable_list": [], "name": "deployCPUa"}, {"description": "", "action_list": [], "service_local_reference_list": [{"kind": "app_service", "name": "code"}], "version": "", "type": "DEB", "options": {"install_runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera"}, "description": "", "child_tasks_local_reference_list": [{"kind": "app_task", "name": "PackageInstallTask"}], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "6405be68_dag"}, {"target_any_local_reference": {"kind": "app_package", "name": "cloudera"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"exit_status": [], "script": "#!/usr/bin/env python\nfrom cm_api.api_client import ApiResource\nfrom cm_api.endpoints.clusters import ApiCluster\nfrom cm_api.endpoints.clusters import create_cluster\nfrom cm_api.endpoints.parcels import ApiParcel\nfrom cm_api.endpoints.parcels import get_parcel\nfrom cm_api.endpoints.cms import ClouderaManager\nfrom cm_api.endpoints.services import ApiService, ApiServiceSetupInfo\nfrom cm_api.endpoints.services import create_service\nfrom cm_api.endpoints.types import ApiCommand, ApiRoleConfigGroupRef\nfrom cm_api.endpoints.role_config_groups import get_role_config_group\nfrom cm_api.endpoints.role_config_groups import ApiRoleConfigGroup\nfrom cm_api.endpoints.roles import ApiRole\nfrom time import sleep\n\nhost_username = 'root'\ncm_repo_url = None\ncdh_version = \"CDH5\" # also valid: \"CDH4\"\ncdh_version_number = \"5\"\n#240\nsleep(240)\n\nhostsIP = [ ]\nhostNames = [ ]\nhostNamesLong = [ ]\nthostNames = [ ]\nthostNames = \"@@{compute.name}@@\"\n#hostsIP = thostsIP.split(,)\nhostNames = thostNames.split(\",\")\n\n#for name in hostName:\n # hostNamesLong = hostName.append(name + '.rf9.local')\n\nfor name in hostNames:\n hostNamesLong.append(name + '.rf9.local')\n print hostNamesLong\n \nprint \"@@{code.cmip}@@\"\nprint \"@@{code.cmPassword}@@\"\n\napi = ApiResource(\"@@{code.cmip}@@\", '7180', \"@@{code.cmAdmin}@@\", \"@@{code.cmPassword}@@\", version=\"@@{code.APIversion}@@\")\n\n#get the CM instance\ncm = api.get_cluster(\"@@{code.clusterName}@@\")\ncm = ClouderaManager(api)\n\n\ncmd = cm.host_install(\"@@{code.hostAdmin}@@\", hostNamesLong, password=\"@@{code.hostPassword}@@\", cm_repo_url=cm_repo_url)\nprint \"Installing hosts. This might take a while.\"\nwhile cmd.success == None:\n sleep(15)\n cmd = cmd.fetch()\n\nif cmd.success != True:\n print \"cm_host_install failed: \" + cmd.resultMessage\n# exit(0)\nprint \"cm_host_install succeeded\"\n\ncluster = api.get_cluster(\"@@{code.clusterName}@@\")\n\nhostsadded = cluster.add_hosts(hostNamesLong)\n\nparcels_list = []\n# get and list all available parcels\nprint \"Available parcels:\"\nfor p in cluster.get_all_parcels():\n print p.version\n if p.version.startswith(\"@@{code.cmPackage}@@\") and p.product == \"CDH\":\n parcels_list.append(p)\n\nif len(parcels_list) == 0:\n print \"No \"\n print cdh_version\n print \" parcel found!\"\n exit(0)\n\ncdh_parcel = parcels_list[0]\n\nfor p in parcels_list:\n if p.version > cdh_parcel.version:\n cdh_parcel = p\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" downloaded\"\n\n# distribute the parcel\nprint \"Starting parcel distribution. This might take a while.\"\ncmd = cdh_parcel.start_distribution()\nif cmd.success != True:\n print \"Parcel distribution failed!\"\n exit(0)\n\nprint 'wait 4 min'\n# make sure the distribution finishes\n#while cdh_parcel.stage != \"DISTRIBUTED\":\nsleep(200)\n# cdh_parcel = get_parcel(api, cdh_parcel.product, '5.13.3-1.cdh5.13.3.p0.2', cluster_name)\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" distributed\"\n\n# activate the parcel\ncmd = cdh_parcel.activate()\nif cmd.success != True:\n print \"Parcel activation failed!\"\n exit(0)\n\n# make sure the activation finishes\n#while cdh_parcel.stage != \"ACTIVATED\":\n# cdh_parcel = get_parcel(api, cdh_parcel.product, '5.13.3-1.cdh5.13.3.p0.2', cluster_name)\n\nprint cdh_parcel.product + ' ' + cdh_parcel.version + \" activated\"\n\n\nyarn = cluster.get_service('yarn')\nprint yarn.name\nhostsid = api.get_all_hosts()\n#range = len(hostsid)\n#print 'range: ' + range\n\nfor current in hostsid:\n if current.rackId == '/default/default':\n print 'host name to add' + current.hostname\n currentshort1 = current.hostname\n currentshort = currentshort1.split(\".\", 1)\n short = currentshort[0]\n print short\n yarn.create_role(short, 'NODEMANAGER', current.hostId)\n\ncluster.restart(restart_only_stale_services=True, redeploy_client_configuration=True)\n\nexit(0)", "script_type": "sh", "type": "", "command_line_args": "", "login_credential_local_reference": {"kind": "app_credential", "name": "go"}}, "timeout_secs": "", "type": "EXEC", "variable_list": [], "name": "PackageInstallTask"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "6405be68_dag"}, "name": "7da2879a_runbook_cloned_1"}, "type": "", "uninstall_runbook": {"variable_list": [], "task_definition_list": [{"target_any_local_reference": {"kind": "app_package", "name": "cloudera"}, "description": "", "child_tasks_local_reference_list": [], "attrs": {"edges": [], "type": ""}, "timeout_secs": "", "type": "DAG", "variable_list": [], "name": "de4520ca_dag"}], "description": "", "main_task_local_reference": {"kind": "app_task", "name": "de4520ca_dag"}, "name": "339b443d_runbook_cloned_1"}}, "variable_list": [], "name": "cloudera"}], "app_profile_list": [{"deployment_create_list": [{"name": "76df5aad_deployment", "action_list": [], "package_local_reference_list": [{"kind": "app_package", "name": "deployCPUa"}], "editables": {"min_replicas": true}, "max_replicas": "1", "substrate_local_reference": {"kind": "app_substrate", "name": "yarn"}, "min_replicas": "1", "variable_list": [], "description": ""}, {"description": "", "action_list": [], "package_local_reference_list": [{"kind": "app_package", "name": "cloudera"}], "max_replicas": "1", "substrate_local_reference": {"kind": "app_substrate", "name": "runner"}, "min_replicas": "1", "variable_list": [], "name": "76df5aad_deployment_cloned_1"}], "variable_list": [], "description": "", "action_list": [], "name": "Default1"}], "default_credential_local_reference": {"kind": "app_credential", "name": "go"}, "client_attrs": {"None": {"y": 450, "x": 810}, "code": {"y": 380, "x": 760}, "compute": {"y": 380, "x": 580}}}, "name": "computeexpand"}, "api_version": "3.0", "metadata": {"last_update_time": "1526503361119604", "creation_time": "1520027297574039", "kind": "blueprint", "spec_version": 85, "name": "computeexpand"}}