azukaar / Cosmos-Server

☁️ The Most Secure and Easy Selfhosted Home Server. Take control of your data and privacy without sacrificing security and stability (Authentication, anti-DDOS, anti-bot)
https://cosmos-cloud.io
Other
2.96k stars 105 forks source link

[FEAT]: CLI app to access host via WWW #162

Open mareczek82 opened 6 months ago

mareczek82 commented 6 months ago

Feature Description

sometimes i cannot use Putty or other CLI app to access my VPS. I tried to lunch cockpit and proxy it via cosmos, but i couldn't make it work (Oracle free tier VPS).

I think it would be very helpful to have such access via cosmos itself or app

JasonLocklin commented 1 month ago

I suggest and am trying to get Wetty working. It's a highly responsive terminal emulator that works behind nginx.

JasonLocklin commented 1 month ago

I got it working: (replace <USER> and <HOSTNAME> -don't use localhost because docker)

{
  "services": {
    "wetty": {
      "container_name": "wetty",
      "image": "wettyoss/wetty",
      "environment": [
        "SSHHOST=<HOSTNAME>",
        "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
        "NODE_VERSION=18.10.0",
        "YARN_VERSION=1.22.19",
        "NODE_ENV=production",
        "SSHUSER=<USER>"
      ],
      "labels": {
        "maintainer": "butlerx@notthe.cloud",
        "org.opencontainers.image.created": "2022-10-09T10:57:10.338Z",
        "org.opencontainers.image.description": "Terminal in browser over http/https. (Ajaxterm/Anyterm alternative, but much better)",
        "org.opencontainers.image.licenses": "MIT",
        "org.opencontainers.image.revision": "d9fb1635ba4c5a8efa9efb6b9da0a5083557f903",
        "org.opencontainers.image.source": "https://github.com/butlerx/wetty",
        "org.opencontainers.image.title": "wetty",
        "org.opencontainers.image.url": "https://github.com/butlerx/wetty",
        "org.opencontainers.image.version": "main"
      },
      "ports": [],
      "volumes": [],
      "networks": {
        "bridge": {}
      },
      "routes": null,
      "restart": "always",
      "devices": null,
      "expose": [],
      "depends_on": [],
      "tty": true,
      "stdin_open": true,
      "entrypoint": "yarn start",
      "working_dir": "/usr/src/app",
      "hostname": "wetty",
      "mac_address": "02:42:ac:11:00:04",
      "network_mode": "default",
      "healthcheck": {
        "test": null,
        "interval": 0,
        "timeout": 0,
        "retries": 0,
        "start_period": 0
      }
    }
  }
}