Shamoon
Shamoon

Reputation: 43599

How do I resolve "Graphics Device initialization failed for : es2, sw" when running on WSL?

I am trying to setup okta-aws-cli-assume-role, but I have a Windows machine (please don't shoot me!). I think my problem is there is some graphical components, and when I run with a Ubuntu WSL, it can't find the appropriate device.

The full error is:

Graphics Device initialization failed for :  es2, sw
Error initializing QuantumRenderer: no suitable pipeline found
java.lang.RuntimeException: java.lang.RuntimeException: Error initializing QuantumRenderer: no suitable pipeline found

What should I do?

Upvotes: 2

Views: 846

Answers (1)

GoodDok
GoodDok

Reputation: 1850

While some may suggest you a workaround for this problem, I suggest you to take a look at aws-sts docker solution: it uses headless browser under the hood, so there won't be any problems related to the graphics and it is more or less platform independent.

I was exactly in the same situation using WSL, so what I did:

  • created config.json as described in the Readme
  • ReadMe suggests to create a Dockerfile, but actually I never had to use it just passing the config parameters to the basic docker image like in the template file

As the result, aws token is generated inside the docker container and put into mounted $HOME/.aws folder, so you can easily call awscli from WLS.

Here is how to make docker working properly with WLS (in short, client in WLS, server installed on Windows with exposed daemon).

One more hint: use --profile=default when generating token, so you don't have to specify it every time you use awscli.

Upvotes: 1

Related Questions