Comments (6)
Thanks for your suggestion! It looks like a useful addition to me, I'll work on an implementation.
from cli.
I added the feature in #716
Can you please confirm that it works for you with
go install github.com/hetznercloud/cli/cmd/hcloud@reset-password-output-options
- or
go run github.com/hetznercloud/cli/cmd/hcloud@reset-password-output-options server reset-password <server> -o=yaml
from cli.
I added the feature in #716
Wow, that was fast :-)
Thanks for your work!
Can you please confirm that it works for you with
I will.
However, I am not as fast as you are ;-)
And pretty busy atm.
I guess I can test the modified hcloud tool in the next few days, aiming at 2024-03-24.
Thanks again, phm07!
best,
edgecode
from cli.
Tried to test, but failed due to my non-existant GO skills:
Unfortunalety I cannot dive into this atm.
@phm07 maybe you could give me a quick hint to set up GO correctly.
I am on a Ubuntu 22.04 machine.
It has GO 1.18 installed in Debian/Ubuntu's standard locations, e.g. /usr/{lib,share,bin}/go-1.18
When I run go install
as a regular user, it downloads hclould code in ./go
and I get:
/home/edge$ go install github.com/hetznercloud/cli/cmd/hcloud@reset-password-output-options
go/pkg/mod/github.com/hetznercloud/[email protected]/internal/cmd/iso/list.go:5:2: package slices is not in GOROOT (/usr/lib/go-1.18/src/slices)
I tried export GOROOT='/usr/lib/go-1.18:/home/edge/go'
which did not help.
Reading the error message closer, I guess my GO installation is missing the slices
package.
I will retry this evening and see how I can install that package.
from cli.
I was able to get things working with go 1.22 :-)
Either I did not get the env vars or go.mod concept of go.
Or the package "slices" is not part of go's standard lib in version 1.18.
For the record: I installed the Canonical official snap package on my Ubuntu 22.04 machine which has many go version on board and defaults to go 1.22.
But back to business:
The modified hcloud cli works :-)
I do get YAML or JSON output when I reset a server's password.
And server reset-password --help lists the output options.
@phm07 Thanks again for your fast implementation of this small, but useful hcloud enhancment.
from cli.
Yea, slices
was only added in Go 1.21, and that is the lowest version we currently support.
Great that it works for you!
I will re-open the issue until the PR is merged, @phm07 will be back next week to take care of that.
from cli.
Related Issues (20)
- The release v1.44.2 failed. HOT 1
- context command line argument HOT 1
- Store token in a more secure manner , support pairs of tokens HOT 5
- Wording when a firewall is removed from resource is wrong
- fix: allow deleting reverse DNS entries
- issue with creating context in interactive mode (hcloud: context create is an interactive command) HOT 8
- fix: formatting broken when creating server with multiple networks
- Consider merging hcloud-upload-image in this tool HOT 4
- hcloud: invalid gateway (invalid_input, xxxxxx) HOT 2
- fix: macos shows error when running binaries (missing notarization) HOT 1
- feat: allow not waiting for actions
- hcloud apt install doesnt work HOT 3
- refactor: re-enable linters and improve code quality
- fix(server-type): inconsistent base for size units in description HOT 1
- fix: `--debug` is sometimes not applied HOT 1
- Improve server types readability for datacenter describe command
- fix: `--context` value is not auto completed HOT 1
- feat(primary-ip): allow setting auto-delete on create
- feat: allow configuring default columns for list commands
- docs: consistent spelling of product names
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cli.