This repository has been archived by the owner on Apr 27, 2023. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ensure the right dependencies are available on TaskCluster
Unfortunately this "hack" is required because the add-ons pipeline does not enable consumers to customize the installed packages.
- Loading branch information
Showing
2 changed files
with
25 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
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 |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this | ||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */ | ||
|
||
import * as exec from "child_process"; | ||
import { promisify } from "util"; | ||
|
||
// Define an async/await version of "exec". | ||
const execAsync = promisify(exec.exec); | ||
|
||
if (!('TASK_ID' in process.env)) { | ||
// If this is not running on TaskCluster, exit | ||
// without an error code. | ||
process.exit(0); | ||
} | ||
|
||
console.log("Running in TaskCluster. Running set-up."); | ||
|
||
// The TaskCluster instance on the Mozilla add-ons pipeline | ||
// does not allow image customization, so python3 venv cannot | ||
// be installed. That package is required for Glean to build. | ||
// We make sure to have all the dependencies in place when on | ||
// TaskCluster by running the commands manually. | ||
execAsync("apt-get -y install python3-venv"); |