flyctl icon indicating copy to clipboard operation
flyctl copied to clipboard

FLY_ORG env var is not respected by redis or pg subcommands

Open indirect opened this issue 2 years ago • 0 comments

Describe the bug Briefly, describe what broke and provide the following details:

The fly pg and fly redis commands both have a bunch of subcommands that operate in an org context, like list, create, etc. However, both commands ignore the FLY_ORG env var, which can be used to set an org for other commands like fly apps.

  • macOS Ventura 13.6
  • fly v0.1.104 darwin/arm64 Commit: 682c341cb1b8fc0bc80589fd96d7cad34f1772f0 BuildDate: 2023-09-29T15:46:28Z

** Paste your fly.toml

none

** Command output: **

❯ FLY_ORG=sunchaser fly redis list
NAME                    ORG             PLAN    EVICTION        PRIMARY REGION  READ REGIONS 
feedyouremail           feedyouremail   Free    Enabled         sjc                         
sunchaser-redis-cache   sunchaser       Free    Enabled         sjc                         
sunchaser-redis         sunchaser       200M    Disabled        sjc  
❯ FLY_ORG=sunchaser fly pg list
NAME                            OWNER           STATUS          LATEST DEPLOY 
rocket-db                       personal        suspended                    
feedyouremail-db                feedyouremail   deployed                     
feedyouremail-staging-db        feedyouremail   suspended                    
sunchaser-db                    sunchaser       deployed                     
sunchaser-preview-db            sunchaser       deployed                     
sunchaser-staging-db            sunchaser       deployed                     

Expected result:

Setting FLY_ORG should filter list by org, and set the --org flag on create, etc.

indirect avatar Oct 05 '23 03:10 indirect