Git Product home page Git Product logo

Comments (17)

Waterdrips avatar Waterdrips commented on May 27, 2024 2

0.4.1 seems to work 👍

from inletsctl.

alexellis avatar alexellis commented on May 27, 2024 1

@adamjohnson01 @utsavanand2 please can you take a look into this?

from inletsctl.

adamjohnson01 avatar adamjohnson01 commented on May 27, 2024 1

@alexellis, @burtonr and @utsavanand2 I know what the issue is and will raise a PR to fix it. The issue is here

_, err = p.gceProvisioner.Instances.Delete(request.ProjectID, request.Zone, instanceName).Do()

I introduced this when I added the delete by IP functionality, the problem is that the project-id from the instance name string is not being used.

Apologies, I did not test the normal delete functionality when I added the delete by ip functionality.

from inletsctl.

Waterdrips avatar Waterdrips commented on May 27, 2024

I also found this with a DO exit node, downgrading to 0.3.9 release worked.

Looks like a regression

from inletsctl.

alexellis avatar alexellis commented on May 27, 2024

I can't reproduce this, it might have been fixed in 0.4.1, please can you guys re-test? https://github.com/inlets/inletsctl/releases/tag/0.4.1

from inletsctl.

burtonr avatar burtonr commented on May 27, 2024

Updated to 0.4.1. The error in the original description is gone, but now there is a different error:

gcp is the .json file that contains the credentials

$ inletsctl delete --provider gce --id "determined-curran1|us-central1-a|burtonr"
Using provider: gce
give a value for --access-token-file or --access-token

$ inletsctl delete --provider gce --id "determined-curran1|us-central1-a|burtonr" -f gcp
Using provider: gce
Deleting host: determined-curran1|us-central1-a|burtonr from gce
could not delete the GCE instance: googleapi: got HTTP response code 404 with body: Not Found

from inletsctl.

alexellis avatar alexellis commented on May 27, 2024

I've personally tested Packet and DO recently and would suggest using those. You can also set up your own VMs the old fashioned way.

Let's see if @utsavanand2 can help with this issue, who wrote the code for GCE

from inletsctl.

utsavanand2 avatar utsavanand2 commented on May 27, 2024

@burtonr I'll take a look at this. I'm having issues with GCE, particularly with the firewall rules with Stackdriver logs stating that I do not have enough permissions. I would be really grateful if I can get some suggestions from you, since I guess you have a GCP account 😄

from inletsctl.

burtonr avatar burtonr commented on May 27, 2024

Hey @utsavanand2 Thanks for helping out. Yes, I use GCP for a lot of my personal projects.
For inletsctl, the service account, or credentials that you pass it, the account must have at least:

  • compute.firewalls.create
    • There is no specific "compute.firewalls" permissions that I could find though, so I set it to Admin
  • serviceaccount user

I have an inlets service account that's set up as "compute admin" and "iam.serviceAccountUser". That worked for setting it all up, but having trouble getting the delete command to work. Compute Admin has enough permission to do everything. I'll go back and make that more specific once I get it all up and running properly

from inletsctl.

utsavanand2 avatar utsavanand2 commented on May 27, 2024

@burtonr If you see here, I am using the compute.Admin role, which has network admin rights too and the serviceaccount user role. But inlets-op seems to have trouble with creating the firewall rules for the inlets control port. Though this is a different topic but can be related, considering the merged PR was working completely fine for a couple of weeks, and suddenly broke. I'm afraid if this is another example of that issue.
I have read the godocs for the google cloud sdk and apparently it is created automatically with gRPC. I don't know if this a result of any inconsistent request formats that might have been updated in the upstream SDK but not in the vendor, but I'm not sure.
Thanks a lot for your input though.
I'll check and see if I can fix it by tomorrow

from inletsctl.

burtonr avatar burtonr commented on May 27, 2024

I see that the import for inlets is "google.golang.org/api/compute/v1"

Looking at the source repo, I see this section in the first paragraph of the readme:

If you're working with Google Cloud Platform APIs such as Datastore or Pub/Sub, consider using the Cloud Client Libraries for Go instead. These are the new and idiomatic Go libraries targeted specifically at Google Cloud Platform Services.

That said, it seems the imports should be updated to: "cloud.google.com/go" from the newer(?) repo here: google-cloud-go

from inletsctl.

utsavanand2 avatar utsavanand2 commented on May 27, 2024

@burtonr I saw that repo initially, but the new repo only had compute/metadata sub module. I may be wrong here though

from inletsctl.

burtonr avatar burtonr commented on May 27, 2024

Ah yes, I see that now. At a quick glance, it looks more complete, and official. Sadly, you are correct.

I also found this closed issue asking the same question: googleapis/google-cloud-go#1605

Basically saying: No, there is no official library for interacting with GCP Compute Engine...

In other words, it's quite possible the server side has changed, but the client library is behind 🤷‍♂

from inletsctl.

adamjohnson01 avatar adamjohnson01 commented on May 27, 2024

@alexellis , this can be closed as a dup of #39

from inletsctl.

alexellis avatar alexellis commented on May 27, 2024

/close

from inletsctl.

alexellis avatar alexellis commented on May 27, 2024

Why don't we set up Derek access for contributors to this repo? Can you help Adam?

from inletsctl.

adamjohnson01 avatar adamjohnson01 commented on May 27, 2024

@alexellis, sure. I can help.

from inletsctl.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.