CLI Offline Mode

Options
Hacksore
Hacksore
Community Member
edited May 2023 in CLI

Hi team & community πŸ‘‹

I know this was posted years back but I am wondering if the team has any appetite to allow for loading secrets from the CLI without internet access?

Considering we can use the 1Password Desktop app offline I don't see why the CLI can't have the same functionality. Happy to discuss this in more detail to help this become a reality.


1Password Version: Not Provided
Extension Version: Not Provided
OS Version: Not Provided

Comments

  • Hey @Hacksore, thank you for reaching out to us, and especially for actively offering to discuss it further with us!

    We do have this in our internal tracker. We cannot make any promises related to when will this get on our short roadmap, but we'll make sure to keep the thread updated, when the case will be :)

    In the meantime, can you tell us more about your use-case, and the environment where you'd benefit from running the CLI offline?

    Thanks!

    Best,
    Horia

  • Hacksore
    Hacksore
    Community Member
    Options

    @Horia.Culea_1P Thanks for following up on this and the CLI has been super useful to get secrets into my apps.

    I've been using the CLI to source env vars for my apps and this works perfectly fine when I have internet access. However, for my use-case it's when I'm on the plane I don't have internet and I can't start my apps the same way as I did before.

    So supporting offline mode would be really nice so I can keep my secrets off the filesystem when possible 😎.

  • Horia.Culea_1P
    edited July 2022
    Options

    Thanks for the extra information! It's always valuable to have the context.
    We'll keep in touch, when we'll have any new developments related to this!

    Best,
    Horia

  • snowy
    snowy
    Community Member
    Options

    just to bump this. offline ability with the cli would be helpful when I don't have internet access. I am working on coding or just working at home with my local devices, NAS etc.. and the cli breaks in Raycast 1password extension cause my internet goes out is rather frustrating/disappointing as its immediate halt in my workflow. so as fall back if it could interact with the local cache of the vault that would be super great!

  • snowy
    snowy
    Community Member
    Options

    one other item is the delay to get the entry. I mean I have decent internet connection 1gig/50mbps (down/up). but latency fluctuation is annoying cause sometimes it is instant other times their is noticeable lag.

  • snowy
    snowy
    Community Member
    Options

    I am going to ping this again. I have been attempting to use references in scripts and while working in a "closed" environment using the cli. These all failed...

    There is no option for internet and there isn't anyway to work around this. So my scripts failed and I couldn't use the cli...

    I really like offline mode or reliable way to work around a situation where getting out to 1password.com isn't an option. Cause it is all great until I hit this hard block.

  • seedzero
    seedzero
    Community Member
    Options

    I've been trying to use the CLI with Ansible, and the lookups really add a lot of time to the execution of scripts. 1.5 seconds per password is far too long

  • Hey all, thanks for inquiring about the offline mode feature. Here is an answer from our developer Slack workspace that provides a bit of insight into the developments of offline mode.

    "There are currently no updates on the internal issue tracking this, and I can't make any promises as to when this will get on our short roadmap. The CLI was built to function without the Desktop App being installed (the cli is often times used in a CI pipeline for example, where the desktop app is not present). For this reason, the CLI communicates directly with the server to fetch the encrypted items and decrypts them locally, just how the Desktop App does. It also leverages a built-in cache for decreasing the number of request it makes but it does not have the caching capabilities of the 1Password Desktop App.
    For the offline feature to be possible communication between the CLI and the Desktop App needs to be implemented to the degree that the CLI can attempt to retrieve the items from the Desktop App's cache directly. This will speed up the retrieval process and will allow for the CLI to work offline, but will require users to have 1Password8 installed. Of course, a smart fallback mechanism should be introduced to serve both the use cases described above. This is a large improvement and therefore an ETA is very hard to determine."

  • snowy
    snowy
    Community Member
    Options

    Awesome thanks for the update! This makes sense each. And I totally understand there are trade offs to consider with the whatever the implementation is. I will keep an eye and hope this gets implemented.

This discussion has been closed.