Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix launchd killing VMWare process at end of script execution #6006

Merged
merged 5 commits into from
May 18, 2020
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Fix alunchd killing VMWare process at end of script execution
nycnewman committed May 17, 2020
commit a5e78e91b1841f67ba84424f47f2cbbee589bf09
11 changes: 10 additions & 1 deletion infra/macos/scripts/README.md
Original file line number Diff line number Diff line change
@@ -11,6 +11,15 @@ Example script for Launchctl scheduled rebuild of MacOS nodes. Run via
launctl load com.digitalasset.macos-builder-crontab.plist
```

and unload via

```bash
launctl unload com.digitalasset.macos-builder-crontab.plist
```

NOTE: AbandonProcessGroup key is requied for VMWare or the started vmx process is sent a SIGTERM signal by launchd,
causing node to halt and not be left running at end of script. Different behaviour to VirtualBox.

## rebuild-crontask.sh

Script called by launchctl job to force destroy and rebuild a VSTS node. Needs a PAT token with job access
@@ -27,4 +36,4 @@ Helper script to build a node. Called from the above script. Needs a PAT token f
* Delete GarageBand, iMovie, KeyNote, Pages, Sheets to save space and avoid annoying Update notification
* May need to download Catalina installer on new release to ensure latest patched version
* Consider creating SSH key pair and distribute public key to other nodes in authorized_keys to distrbute
files more easily
files more easily
Original file line number Diff line number Diff line change
@@ -21,6 +21,12 @@
<key>RunAtLoad</key>
<false/>

<key>AbandonProcessGroup</key>
<true/>

<key>RunAtLoad</key>
<false/>

<key>StandardErrorPath</key>
<string>/Users/builder/rebuild-crontab.err</string>