UNPKG

firebase-tools

Version:
33 lines (32 loc) • 1.22 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.RUN_PERMISSIONS = void 0; exports.prereqs = prereqs; const ensureApiEnabled_1 = require("../../ensureApiEnabled"); const artifactregistry = require("../../gcp/artifactregistry"); exports.RUN_PERMISSIONS = [ "run.services.get", "run.services.create", "run.services.update", "run.services.setIamPolicy", "run.operations.get", "cloudbuild.builds.create", "cloudbuild.builds.get", "storage.buckets.get", "storage.buckets.list", "storage.buckets.create", "storage.buckets.update", "storage.objects.create", "artifactregistry.repositories.get", "artifactregistry.repositories.create", "artifactregistry.repositories.downloadArtifacts", "iam.serviceAccounts.actAs", ]; async function prereqs(projectId) { await Promise.all([ (0, ensureApiEnabled_1.ensure)(projectId, "run.googleapis.com", "run", true), (0, ensureApiEnabled_1.ensure)(projectId, "cloudbuild.googleapis.com", "cloudbuild", true), (0, ensureApiEnabled_1.ensure)(projectId, "storage.googleapis.com", "storage", true), artifactregistry.ensureApiEnabled(projectId), ]); }