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

Installed the npm package but when I run pulumi up I get the following error #6

Open
algoflows opened this issue Apr 25, 2022 · 0 comments
Labels
kind/bug Some behavior is incorrect or out of spec

Comments

@algoflows
Copy link

algoflows commented Apr 25, 2022

What happened?

Installed the npm package but when I run "pulumi up" command I get the following error

error: no resource plugin 'pulumi-resource-gcp-global-cloudrun' found in the workspace at version v0.0.3 or on your $PATH, install the plugin using `pulumi plugin install resource gcp-global-cloudrun v0.0.3`

here you can see the file where I use gcp-global-cloudrun

// Main provider libraries and sdks
import * as pulumi from '@pulumi/pulumi';
import * as docker from '@pulumi/docker';
import * as gcp from '@pulumi/gcp';
import * as cloudrun from '@pulumi/gcp-global-cloudrun';

// Variables
import { variables } from './project.variables';

// Module imports
import { storage } from './src.modules/storage';

// Commented out not to disable the service at every destroy
const apiServices = [
  'run.googleapis.com',
  'container.googleapis.com',
  'iam.googleapis.com',
  'cloudbuild.googleapis.com',
  'storage.googleapis.com',
  'logging.googleapis.com',
  'pubsub.googleapis.com',
  'cloudresourcemanager.googleapis.com',
  'cloudkms.googleapis.com',
  'cloudfunctions.googleapis.com',
  'cloudtrace.googleapis.com',
  'compute.googleapis.com',
  'containerregistry.googleapis.com',
  'containeranalysis.googleapis.com',
  'dataproc.googleapis.com',
];
// Loop that enable service apis list for the projects
const apis = apiServices.map(
  (name) =>
    new gcp.projects.Service(name, {
      service: name,
    })
);

// Create Storage Resources - src-modules/storage
const bucket = storage.bucket;
const acl = storage.acl;
const bucketObject = storage.bucketObject;
// outputs
export const bucketUrl = storage.url;

// Containers Cloud Run
const myImage = new docker.Image(
  'remix-image',
  {
    imageName: 'gcr.io/ps-pulumi/remix-image',
    build: {
      context: '../remix',
    },
  },
  { dependsOn: [...apis] }
);

export const imageName = myImage.imageName;

const deployment = new cloudrun.Deployment('my-sample-deployment', {
  projectId: variables.project!!,

  imageName: 'gcr.io/ps-pulumi/remix-image',
  serviceName: 'demo-service-ts',
});

export const ip = deployment.ipAddress;

Steps to reproduce

  • Create pulumi project
  • Give correct permissions
  • Import global cloud run package
  • Copy over docs
  • Pulumi up

----> Error

Expected Behavior

Pulumi Up finishes and can deploy global infrastructure

Actual Behavior

Error

Screenshot 2022-04-25 at 09 59 30

Tried resolutions

Followed the initial error messages instructions to install the Pulumi plugin, but then get the following error.

Screenshot 2022-04-25 at 10 07 33

Versions used

Latest on NPM

"@pulumi/gcp-global-cloudrun": "^0.0.3",

Additional context

Thanks for the help and putting this package together, it's exactly what I've been looking for... if it worked ;) ✋🏻

Contributing

Vote on this issue by adding a 👍 reaction.
To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).

@stack72 stack72 added bug Something isn't working kind/bug Some behavior is incorrect or out of spec and removed bug Something isn't working labels Apr 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Some behavior is incorrect or out of spec
Projects
None yet
Development

No branches or pull requests

2 participants