Skip to content

Allow [or document how to] save/load local server configuration #253

Description

@DiamondJoseph

I'm trying to move a legacy service running on Tomcat such that the development environment uses local dummy services instead of needing the live service. Therefore, I need a repeatable server configuration with minimal configuration, such that users who are familiar with Tomcat but not devcontainers can make quick use of it with a basic readme.

My devcontainer json contains the following, so I have a local version of Tomcat, Java and have the plugin installed by default:

	// Features to add to the dev container. More info: https://containers.dev/features.
	"features": {
		"ghcr.io/devcontainers/features/java:1": {
			"installMaven": true,
			"version": "21",
			"additionalVersions": "8" // Java 21 required for pre-commit, actually targets Java 8
		},
		"ghcr.io/prulloac/devcontainer-features/pre-commit:1.0.3": {},
    	"ghcr.io/devcontainers-extra/features/tomcat-sdkman:2": {
			"version": "9.0.118",  // Latest version in SDKMan
			"jdkVersion": "8"
		}
	},

	// Configure tool-specific properties.
	"customizations": {
		"vscode": {
			"extensions": [
				"redhat.vscode-community-server-connector"
			]
		}
	}

When I tried putting the json exposed by Edit server in .vscode/servers.json the launch failed due to trying to connect and run the devcontainer on the remote. Can I put this anywhere (or as a launch.json entry?) or have an option for Create new server [from json] so that I can have a simple 1-3 line readme on how to launch the service entirely locally?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions