Do current docker images support VSCode extensions out of the box?

Neither image’s package.json has the necessary dependencies.

Is this deliberate or are the Docker images outdated?
How would you recommend I extend the base image to add the necessary dependencies?

If I build from source it works perfectly fine, but I’m not exactly sure how to use the built version in a docker production environment.

Thanks in advance.

theia:latest

{
    "private": true,
    "theia": {
        "frontend": {
            "config": {
                "applicationName": "Theia JavaScript/TypeScript Example",
                "preferences": {
                    "files.enableTrash": false
                }
            }
        }
    },
    "dependencies": {
        "@theia/callhierarchy": "latest",
        "@theia/debug": "latest",
        "@theia/debug-nodejs": "latest",
        "@theia/file-search": "latest",
        "@theia/git": "latest",
        "@theia/json": "latest",
        "@theia/markers": "latest",
        "@theia/merge-conflicts": "latest",
        "@theia/messages": "latest",
        "@theia/mini-browser": "latest",
        "@theia/navigator": "latest",
        "@theia/outline-view": "latest",
        "@theia/preferences": "latest",
        "@theia/preview": "latest",
        "@theia/search-in-workspace": "latest",
        "@theia/terminal": "latest",
        "@theia/textmate-grammars": "latest",
        "@theia/tslint": "latest",
        "@theia/typescript": "latest",
        "typescript": "latest"
    },
    "resolutions": {
        "vscode-languageserver-protocol": "3.15.0-next.9",
        "vscode-languageserver-types": "3.15.0-next.5"
      },
    "devDependencies": {
        "@theia/cli": "latest"
    }
}

theia:next

{
    "private": true,
    "theia": {
        "frontend": {
            "config": {
                "applicationName": "Theia JavaScript/TypeScript Example",
                "preferences": {
                    "files.enableTrash": false
                }
            }
        }
    },
    "dependencies": {
        "@theia/callhierarchy": "next",
        "@theia/debug": "next",
        "@theia/debug-nodejs": "next",
        "@theia/editor-preview": "next",
        "@theia/file-search": "next",
        "@theia/getting-started": "next",
        "@theia/git": "next",
        "@theia/json": "next",
        "@theia/markers": "next",
        "@theia/merge-conflicts": "next",
        "@theia/messages": "next",
        "@theia/mini-browser": "next",
        "@theia/navigator": "next",
        "@theia/outline-view": "next",
        "@theia/preferences": "next",
        "@theia/preview": "next",
        "@theia/search-in-workspace": "next",
        "@theia/terminal": "next",
        "@theia/textmate-grammars": "next",
        "@theia/typescript": "next",
        "@theia/tslint": "next",
        "typescript": "latest"
    },
      "resolutions": {
        "vscode-languageserver-protocol": "3.15.0-next.9",
        "vscode-languageserver-types": "3.15.0-next.5"
      },
    "devDependencies": {
        "@theia/cli": "next"
    }
}

[original thread by Ezequiel]

[Soumesh Banerjee]

I also had something similar requirements, I end up creating my own docker image there I COPY the theia-extension project source and also wrote a simple script to pull the .vsix file using Github release API and COPY it too.

Maybe there are simpler way to achieve this!

Hi, sorry, not it is no deliberate, we don’t have time unfortunately. We also working on finishing webviews and theming. It would be last 2 big chunks to support all VS Code built-in extensions, after that it would make sense to reconfigure all theia-apps images.

https://github.com/theia-ide/theia-apps/tree/master/theia-go-docker is using VS Code extension already, you can have a look how it is done.

Although it is misusing “download-debug-adapters” scripts and access MS marketplace which strictly speaking legal to use only from Visual Studio products. Open source alternative of VS Code marketplace is in working right now as well: https://github.com/theia-ide/extension-registry

[Ezequiel]

Thanks for the answers!

I’ve built my own Docker image from source, but that leaves a whole bunch of dev dependencies in my image.
Edit: I guess I should clone the repository, leave only the contents of /example/browser (for my use case, of course), and then build it.

Perhaps @sudoo 's way is better, as you can just copy the package.json from their browser example.

I understand @anton-kosyakov, will try to get a little bit more familiar with the source code and examples.
Is there a repository where you test the “newest”, “fullest”, theia? Or is it a “grab what you need” kind of thing.
Edit: Would that be the examples repository? I mean that is where I’ve built from source.

Examples in the theia repo are internal clients for new changes.

Applications should be built according to https://theia-ide.org/docs/composing_applications/, i.e. from published npm packages.

There is no fullest Theia :slight_smile: Theia is an IDE framework, not a final product. Yes, you grad what you need and add some your stuff.

I hope we align though theia-ide/theia docker with standard VS Code next year.

[Ezequiel]

Sorry for the delay, got it, thanks for you time Anton!