Giter Club home page Giter Club logo

Comments (14)

unusualevent avatar unusualevent commented on June 2, 2024

that would be useful to script together:

old_image=$(ops image list --json --filter "somename" | jq 'sort to newest')
go build thing.go
ops image create imgname -t vultr
# get single ID instead of a table
image_tag=$(ops image list --json | jq 'sort to newest....')
# launch newer instances
for i in 1..5; do
ops instance create $image_tag -t vultr --label somelabel --domain $i.somedomain
done
sleep 10m # let the cluster heal
# kill the old instances
for instance in $(ops instance list --filter $old_image); do
ops instance delete $instance -t vultr
done

from ops.

eyberg avatar eyberg commented on June 2, 2024

since we have so many providers/targets we sometimes don't add functionality for everything at once - this should be relatively easy to do though; happy to accept any prs for it

from ops.

unusualevent avatar unusualevent commented on June 2, 2024

how ugly can the PR be? I'm also after getting the labels / domain names / names built - are you expecting PRs to have no new dependencies or something?

from ops.

eyberg avatar eyberg commented on June 2, 2024

we are totally ok with prs that don't diverge much from existing behavior and add incremental benefits/features

I think we can merge things that are shorter/feature specific much faster than larger changes - if you have completely different requests I'd break those up into diff prs

as for including new deps - we'd like to avoid that as much as we can - there's already a lot of existing 3rd party software that's included - good chance you can find existing behavior elsewhere in the code that could be re-used

from ops.

unusualevent avatar unusualevent commented on June 2, 2024

@eyberg looking through this trying to find an example of where I would need to extend the provider.

from ops.

unusualevent avatar unusualevent commented on June 2, 2024

added to PR #1462

from ops.

eyberg avatar eyberg commented on June 2, 2024

thanks!

from ops.

unusualevent avatar unusualevent commented on June 2, 2024

@eyberg note - I can't build this locally. You're on 1.19.5 and I was using go1.20.3 - so I guess it's gonna have to wait until a new release artifact is published.

from ops.

eyberg avatar eyberg commented on June 2, 2024

the version shouldn't matter; if you're running into a build issue that is a diff. problem (possibly protobufs?)

from ops.

unusualevent avatar unusualevent commented on June 2, 2024

distribution/distribution#3590 <- it's this. my checksum db doesn't match the one you checked into the repo, when I clean the cache and retry it.

from ops.

eyberg avatar eyberg commented on June 2, 2024

oh, you could nuke the gosum, bump go.mod deps and you'll prob be ok

from ops.

unusualevent avatar unusualevent commented on June 2, 2024

nice, so this works vultr=$(ops instance list -t vultr --json | jq -r '.[] | select(.tag=="nanos")|.main_ip') - I just had to add the "nanos" tag to the instance after it was made.

Is there an existing convention/preference if I add hostnames/labels/tags to the vultr part of the cli? that would make filtering using JQ a little easier. Is the cli option supposed to be something like --label?

from ops.

eyberg avatar eyberg commented on June 2, 2024

yes - we add tags to a handful of providers today such as aws (https://github.com/nanovms/ops/blob/master/provider/aws/aws_image.go#L118) and gcp ( https://github.com/nanovms/ops/blob/master/provider/gcp/gcp_instance.go#L42 ) and filter everything based on that - we can/should do the same for vultr as it's very common to have a mix of nanos instances and non-nanos instances

from ops.

eyberg avatar eyberg commented on June 2, 2024

added tags for vultr instances here #1472 - i didn't see offhand a way to do this for snapshots

from ops.

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.