Skip to content

fix: --json should not show human steps #4250

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

matthiaz
Copy link

As a human, yes I want human readable steps.
But If I'm asking for --json, I really don't expect those steps to break my json.

Current behaviour

flyctl certs show yourdomain.be --app $NAME --json                            
{
    "ID": "cert_1235ln",
    "AcmeDNSConfigured": false,
    "AcmeALPNConfigured": false,
    "Configured": false,
    "CertificateAuthority": "lets_encrypt",
    "CreatedAt": "2025-03-14T11:11:23Z",
    "DNSProvider": "cloudflare",
...
    "Hostname": "yourdomain.be",
    "Source": "fly",
    "ClientStatus": "Awaiting configuration",
    "IsApex": false,
    "IsWildcard": false,
    "Issued": {
        "Nodes": []
    }
}

You are creating a certificate for yourdomain.be
We are using Let's Encrypt for this certificate.

You can configure your DNS for yourdomain.be by:

1: Adding an CNAME record to your DNS service which reads:

    CNAME test. yourdomain-test.fly.dev

Notice the human readable 'next steps' that should not be there when using --json

after this change

flyctl certs show yourdomain.be --app $NAME --json                            
{
    "ID": "cert_1235ln",
    "AcmeDNSConfigured": false,
    "AcmeALPNConfigured": false,
    "Configured": false,
    "CertificateAuthority": "lets_encrypt",
    "CreatedAt": "2025-03-14T11:11:23Z",
    "DNSProvider": "cloudflare",
...
    "Hostname": "yourdomain.be",
    "Source": "fly",
    "ClientStatus": "Awaiting configuration",
    "IsApex": false,
    "IsWildcard": false,
    "Issued": {
        "Nodes": []
    }
}

…rted in human readable text. Makes parsing a command json output difficult.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant