Question: Standard way to freeze Flutter + Android tooling across OS changes (Docker)?

I frequently change Linux distros, and every time my Flutter + Android setup breaks (Flutter SDK, Android SDK, Gradle, Java, IntelliJ/VS Code config).

I’m planning to use Docker + Dev Containers to freeze the entire toolchain (Flutter SDK, Android SDK, Java 17, Gradle), while running the Android emulator on the host and connecting via ADB.
VS Code via Dev Containers, IntelliJ via Docker-based SDK paths.

Goal: one-command setup, no SDKs on host.

Is this a good long-term approach, and can someone help validate or guide the correct setup?

I made this 2 years ago, it’s pretty basic, I’m no docker expert, used it for a few weeks, because there was some bug in android studio that broke my environment.

So I forked the mentioned repo and added flutter inside it. I don’t know if it still works, but it might be able to give you some pointers.

I have only modified the dockerfile, compose.yml doesn’t work and looks like I had to run flutter doctor manually after building it.

Thank you, let me try it out