Skip to content
This repository has been archived by the owner on Oct 4, 2024. It is now read-only.

--keyPath option removed #1103

Open
wackazong opened this issue Feb 29, 2024 · 5 comments
Open

--keyPath option removed #1103

wackazong opened this issue Feb 29, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@wackazong
Copy link

Describe the bug
It seems the --keyPath option was removed silently from near-cli

To Reproduce
Using the option is not recogized by near-cli, it was removed from the code

Expected behavior
Either document this as a change, or preferrably, bring it back.

@gagdiez
Copy link
Contributor

gagdiez commented Feb 29, 2024

where did you find this documented? I did not see it in our docs or the README here

@wackazong
Copy link
Author

wackazong commented Feb 29, 2024

8895ea7#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5L1331

For me it was rather useful in scripted deployments using bash process substitution and sourcing the key json from 1Password.

@gagdiez
Copy link
Contributor

gagdiez commented Mar 1, 2024

I removed --keypath and added near add-credentials. This is because near-cli / near-api-js already have a simple logic to handle key-stores, and options such as --keypath makes us need to handle different cases.

Do you think you could use near add-credentials to import the key into near-cli?

@wackazong
Copy link
Author

Storing the credentials unencrypted on disk is a security issue IMHO. I would prefer --keyPath. Or, even better, an env var that can be used to supply the private key.

@gagdiez
Copy link
Contributor

gagdiez commented Mar 4, 2024

ok, I think I have a simple way to bring this back, and we can use env vars to make it clean. Give me some time to code it and will ping you back.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants