From 87f49f216347fe2bd33aada6ec2fca5543c92bd9 Mon Sep 17 00:00:00 2001 From: Ilya Buziuk Date: Wed, 25 Mar 2026 14:42:12 +0100 Subject: [PATCH 1/3] feat: adding web terminal ttyd editor definition Signed-off-by: Ilya Buziuk --- .../che-web-terminal-latest.yaml | 79 +++++++++++++++++++ 1 file changed, 79 insertions(+) create mode 100644 editors-definitions/che-web-terminal-latest.yaml diff --git a/editors-definitions/che-web-terminal-latest.yaml b/editors-definitions/che-web-terminal-latest.yaml new file mode 100644 index 000000000..390feefec --- /dev/null +++ b/editors-definitions/che-web-terminal-latest.yaml @@ -0,0 +1,79 @@ +# +# Copyright (c) 2026 Red Hat, Inc. +# This program and the accompanying materials are made +# available under the terms of the Eclipse Public License 2.0 +# which is available at https://www.eclipse.org/legal/epl-2.0/ +# +# SPDX-License-Identifier: EPL-2.0 +# +# Contributors: +# Red Hat, Inc. - initial API and implementation +# + +schemaVersion: 2.3.0 +metadata: + name: che-web-terminal + displayName: Web Terminal + description: Web-based terminal using ttyd for Eclipse Che + tags: + - terminal + - ttyd + attributes: + arch: + - x86_64 + - arm64 + - s390x + - ppc64le + publisher: che-incubator + version: latest + title: Web Terminal for Eclipse Che + repository: https://github.com/tsl0922/ttyd + firstPublicationDate: '2026-04-01' + iconMediatype: image/svg+xml + iconData: | + + + $ + + $ + + $ + + + + + +components: + - name: web-terminal-runtime + container: + image: tsl0922/ttyd:latest + mountSources: true + args: + - --port + - "7681" + - --writable + - -w + - /projects + - /bin/bash + memoryLimit: 1024Mi + memoryRequest: 256Mi + cpuLimit: 500m + cpuRequest: 30m + endpoints: + - name: web-terminal + attributes: + type: main + cookiesAuthEnabled: true + discoverable: false + urlRewriteSupported: true + targetPort: 7681 + exposure: public + secure: true + protocol: https + attributes: + app.kubernetes.io/component: web-terminal-runtime + app.kubernetes.io/part-of: web-terminal.eclipse.org + controller.devfile.io/container-contribution: true + +attributes: + version: null From 30060185127d38284add7fc993cf5c1548c4008f Mon Sep 17 00:00:00 2001 From: Ilya Buziuk Date: Fri, 27 Mar 2026 14:25:06 +0100 Subject: [PATCH 2/3] fixup! update the definition Signed-off-by: Ilya Buziuk --- .../che-web-terminal-latest.yaml | 58 ++++++++++++------- 1 file changed, 38 insertions(+), 20 deletions(-) diff --git a/editors-definitions/che-web-terminal-latest.yaml b/editors-definitions/che-web-terminal-latest.yaml index 390feefec..d0ec8c24f 100644 --- a/editors-definitions/che-web-terminal-latest.yaml +++ b/editors-definitions/che-web-terminal-latest.yaml @@ -43,37 +43,55 @@ metadata: +commands: + - id: init-ttyd-command + apply: + component: ttyd-injector +events: + preStart: + - init-ttyd-command components: - - name: web-terminal-runtime + - name: ttyd-injector container: - image: tsl0922/ttyd:latest - mountSources: true - args: - - --port - - "7681" - - --writable - - -w - - /projects - - /bin/bash - memoryLimit: 1024Mi - memoryRequest: 256Mi + image: docker.io/tsl0922/ttyd:1.7.7-alpine + command: + - sh + - -c + - cp /usr/bin/ttyd /ttyd-vol/ttyd && chmod +x /ttyd-vol/ttyd + volumeMounts: + - name: ttyd-volume + path: /ttyd-vol + memoryLimit: 64Mi + memoryRequest: 16Mi cpuLimit: 500m cpuRequest: 30m + - name: ttyd-runtime + attributes: + app.kubernetes.io/component: web-terminal-runtime + app.kubernetes.io/part-of: web-terminal.eclipse.org + controller.devfile.io/container-contribution: true + container: + image: docker.io/tsl0922/ttyd:1.7.7-alpine + memoryLimit: 128Mi + memoryRequest: 32Mi + cpuLimit: 500m + cpuRequest: 30m + volumeMounts: + - name: ttyd-volume + path: /ttyd-vol endpoints: - name: web-terminal + targetPort: 7681 + exposure: public + protocol: https attributes: type: main cookiesAuthEnabled: true discoverable: false urlRewriteSupported: true - targetPort: 7681 - exposure: public - secure: true - protocol: https - attributes: - app.kubernetes.io/component: web-terminal-runtime - app.kubernetes.io/part-of: web-terminal.eclipse.org - controller.devfile.io/container-contribution: true + - name: ttyd-volume + volume: + ephemeral: true attributes: version: null From 23c576ecf3c27eda16b289afae4c9582bc581662 Mon Sep 17 00:00:00 2001 From: Ilya Buziuk Date: Fri, 27 Mar 2026 15:06:27 +0100 Subject: [PATCH 3/3] fixup! web terminal start command Signed-off-by: Ilya Buziuk --- .../che-web-terminal-latest.yaml | 31 ++++--------------- 1 file changed, 6 insertions(+), 25 deletions(-) diff --git a/editors-definitions/che-web-terminal-latest.yaml b/editors-definitions/che-web-terminal-latest.yaml index d0ec8c24f..de0a0804e 100644 --- a/editors-definitions/che-web-terminal-latest.yaml +++ b/editors-definitions/che-web-terminal-latest.yaml @@ -44,27 +44,14 @@ metadata: commands: - - id: init-ttyd-command - apply: - component: ttyd-injector + - id: start-ttyd-command + exec: + component: ttyd-runtime + commandLine: /usr/bin/ttyd -p 7681 /bin/sh events: - preStart: - - init-ttyd-command + postStart: + - start-ttyd-command components: - - name: ttyd-injector - container: - image: docker.io/tsl0922/ttyd:1.7.7-alpine - command: - - sh - - -c - - cp /usr/bin/ttyd /ttyd-vol/ttyd && chmod +x /ttyd-vol/ttyd - volumeMounts: - - name: ttyd-volume - path: /ttyd-vol - memoryLimit: 64Mi - memoryRequest: 16Mi - cpuLimit: 500m - cpuRequest: 30m - name: ttyd-runtime attributes: app.kubernetes.io/component: web-terminal-runtime @@ -76,9 +63,6 @@ components: memoryRequest: 32Mi cpuLimit: 500m cpuRequest: 30m - volumeMounts: - - name: ttyd-volume - path: /ttyd-vol endpoints: - name: web-terminal targetPort: 7681 @@ -89,9 +73,6 @@ components: cookiesAuthEnabled: true discoverable: false urlRewriteSupported: true - - name: ttyd-volume - volume: - ephemeral: true attributes: version: null