• How to enable GUI mode for the aws-azure-login docker container

    2 min read

    If you use Azure Active Directory to provide SSO login you might be using aws-azure-login to use the normal Azure AD login (including MFA) from the command line to create a federated AWS session, placing the temporary credentials for the AWS CLI and other tools like Terraform to use them

    If the tool is failing you might need to use the GUI mode to check what's going on, but if you are using the docker container you will get the following error instead:

    $ aws-azure-login --profile prod --mode=gui
    Logging in with profile 'prod'...
    Using AWS SAML endpoint https://signin.aws.amazon.com/saml
    Error: Failed to launch the browser process!
    Fontconfig warning: "/etc/fonts/fonts.conf", line 100: unknown element "blank"
    [16:16:1122/083057.367058:ERROR:browser_main_loop.cc(1425)] Unable to open X display.
    
    
    TROUBLESHOOTING: https://github.com/puppeteer/puppeteer/blob/main/docs/troubleshooting.md
    
        at onClose (/aws-azure-login/node_modules/puppeteer/lib/cjs/puppeteer/node/BrowserRunner.js:194:20)
        at ChildProcess.<anonymous> (/aws-azure-login/node_modules/puppeteer/lib/cjs/puppeteer/node/BrowserRunner.js:185:79)
        at ChildProcess.emit (events.js:387:35)
        at ChildProcess.emit (domain.js:470:12)
        at Process.ChildProcess._handle.onexit (internal/child_process.js:277:12)
    

    23/11/2021

    Read more...

From pet to cattle
Treat your kubernetes clusters like cattle, not pets