From 2b50ada8826aa134552b7c5bd3dced29fe616222 Mon Sep 17 00:00:00 2001 From: okxlin Date: Thu, 14 Dec 2023 21:23:31 +0800 Subject: [PATCH] =?UTF-8?q?feat:=E6=B7=BB=E5=8A=A0dockge=E5=88=B0=E5=88=97?= =?UTF-8?q?=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/dockge/1.3.3/.env.sample | 4 + apps/dockge/1.3.3/data.yml | 24 ++++ apps/dockge/1.3.3/docker-compose.yml | 23 ++++ apps/dockge/README.md | 165 ++++++++++++++++++++++++++ apps/dockge/data.yml | 20 ++++ apps/dockge/latest/.env.sample | 4 + apps/dockge/latest/data.yml | 24 ++++ apps/dockge/latest/docker-compose.yml | 23 ++++ apps/dockge/logo.png | Bin 0 -> 3286 bytes 9 files changed, 287 insertions(+) create mode 100644 apps/dockge/1.3.3/.env.sample create mode 100644 apps/dockge/1.3.3/data.yml create mode 100644 apps/dockge/1.3.3/docker-compose.yml create mode 100644 apps/dockge/README.md create mode 100644 apps/dockge/data.yml create mode 100644 apps/dockge/latest/.env.sample create mode 100644 apps/dockge/latest/data.yml create mode 100644 apps/dockge/latest/docker-compose.yml create mode 100644 apps/dockge/logo.png diff --git a/apps/dockge/1.3.3/.env.sample b/apps/dockge/1.3.3/.env.sample new file mode 100644 index 00000000..69ba934e --- /dev/null +++ b/apps/dockge/1.3.3/.env.sample @@ -0,0 +1,4 @@ +CONTAINER_NAME="dockge" +PANEL_APP_PORT_HTTP="40186" +DATA_PATH="./data" +STACKS_PATH="/opt/dockge/stacks" diff --git a/apps/dockge/1.3.3/data.yml b/apps/dockge/1.3.3/data.yml new file mode 100644 index 00000000..c0f692e0 --- /dev/null +++ b/apps/dockge/1.3.3/data.yml @@ -0,0 +1,24 @@ +additionalProperties: + formFields: + - default: 40186 + edit: true + envKey: PANEL_APP_PORT_HTTP + labelEn: Port + labelZh: 端口 + required: true + rule: paramPort + type: number + - default: ./data + edit: true + envKey: DATA_PATH + labelEn: Data folder path + labelZh: 数据文件夹路径 + required: true + type: text + - default: /opt/dockge/stacks + edit: true + envKey: STACKS_PATH + labelEn: compose yml folder path (Absolute Path) + labelZh: compose 编排文件路径 (绝对路径) + required: true + type: text diff --git a/apps/dockge/1.3.3/docker-compose.yml b/apps/dockge/1.3.3/docker-compose.yml new file mode 100644 index 00000000..49b9e9c8 --- /dev/null +++ b/apps/dockge/1.3.3/docker-compose.yml @@ -0,0 +1,23 @@ +version: '3' +services: + dockge: + container_name: ${CONTAINER_NAME} + restart: always + networks: + - 1panel-network + ports: + - "${PANEL_APP_PORT_HTTP}:5001" + volumes: + - /var/run/docker.sock:/var/run/docker.sock + - ${DATA_PATH}:/app/data + - ${STACKS_PATH}:/opt/stacks + # - /root/.docker/:/root/.docker + environment: + - DOCKGE_STACKS_DIR=/opt/stacks + image: louislam/dockge:1.3.3 + labels: + createdBy: "Apps" + +networks: + 1panel-network: + external: true diff --git a/apps/dockge/README.md b/apps/dockge/README.md new file mode 100644 index 00000000..1f18756a --- /dev/null +++ b/apps/dockge/README.md @@ -0,0 +1,165 @@ +
+ +
+ +# Dockge + +A fancy, easy-to-use and reactive self-hosted docker compose.yaml stack-oriented manager. + +![GitHub Repo stars](https://img.shields.io/github/stars/louislam/dockge?logo=github) ![Docker Pulls](https://img.shields.io/docker/pulls/louislam/dockge?logo=docker) ![Docker Image Version (latest semver)](https://img.shields.io/docker/v/louislam/dockge/latest?label=docker%20image%20ver.) ![GitHub last commit (branch)](https://img.shields.io/github/last-commit/louislam/dockge/master?logo=github) + + + +View Video: https://youtu.be/AWAlOQeNpgU?t=48 + +## ⭐ Features + +- Manage `compose.yaml` + - Create/Edit/Start/Stop/Restart/Delete + - Update Docker Images +- Interactive Editor for `compose.yaml` +- Interactive Web Terminal +- Reactive + - Everything is just responsive. Progress (Pull/Up/Down) and terminal output are in real-time +- Easy-to-use & fancy UI + - If you love Uptime Kuma's UI/UX, you will love this one too +- Convert `docker run ...` commands into `compose.yaml` +- File based structure + - Dockge won't kidnap your compose files, they are stored on your drive as usual. You can interact with them using normal `docker compose` commands + + + +![](https://github.com/louislam/dockge/assets/1336778/89fc1023-b069-42c0-a01c-918c495f1a6a) + +## 🔧 How to Install + +Requirements: +- [Docker](https://docs.docker.com/engine/install/) 20+ / Podman +- (Podman only) podman-docker (Debian: `apt install podman-docker`) +- OS: + - Major Linux distros that can run Docker/Podman such as: + - ✅ Ubuntu + - ✅ Debian (Bullseye or newer) + - ✅ Raspbian (Bullseye or newer) + - ✅ CentOS + - ✅ Fedora + - ✅ ArchLinux + - ❌ Debian/Raspbian Buster or lower is not supported + - ❌ Windows (Will be supported later) +- Arch: armv7, arm64, amd64 (a.k.a x86_64) + +### Basic + +- Default Stacks Directory: `/opt/stacks` +- Default Port: 5001 + +``` +# Create directories that store your stacks and stores Dockge's stack +mkdir -p /opt/stacks /opt/dockge +cd /opt/dockge + +# Download the compose.yaml +curl https://raw.githubusercontent.com/louislam/dockge/master/compose.yaml --output compose.yaml + +# Start the server +docker compose up -d + +# If you are using docker-compose V1 or Podman +# docker-compose up -d +``` + +Dockge is now running on http://localhost:5001 + +### Advanced + +If you want to store your stacks in another directory, you can generate your compose.yaml file by using the following URL with custom query strings. + +``` +# Download your compose.yaml +curl "https://dockge.kuma.pet/compose.yaml?port=5001&stacksPath=/opt/stacks" --output compose.yaml +``` + +- port=`5001` +- stacksPath=`/opt/stacks` + +Interactive compose.yaml generator is available on: +https://dockge.kuma.pet + +## How to Update + +```bash +cd /opt/dockge +docker compose pull && docker compose up -d +``` + +## Screenshots + +![](https://github.com/louislam/dockge/assets/1336778/e7ff0222-af2e-405c-b533-4eab04791b40) + + +![](https://github.com/louislam/dockge/assets/1336778/7139e88c-77ed-4d45-96e3-00b66d36d871) + +![](https://github.com/louislam/dockge/assets/1336778/f019944c-0e87-405b-a1b8-625b35de1eeb) + +![](https://github.com/louislam/dockge/assets/1336778/a4478d23-b1c4-4991-8768-1a7cad3472e3) + + +## Motivations + +- I have been using Portainer for some time, but for the stack management, I am sometimes not satisfied with it. For example, sometimes when I try to deploy a stack, the loading icon keeps spinning for a few minutes without progress. And sometimes error messages are not clear. +- Try to develop with ES Module + TypeScript (Originally, I planned to use Deno or Bun.js, but they don't have support for arm64, so I stepped back to Node.js) + +If you love this project, please consider giving it a ⭐. + + +## 🗣️ Community and Contribution + +### Bug Report +https://github.com/louislam/dockge/issues + +### Ask for Help / Discussions +https://github.com/louislam/dockge/discussions + +### Translation +If you want to translate Dockge into your language, please read [Translation Guide](https://github.com/louislam/dockge/blob/master/frontend/src/lang/README.md) + +### Create a Pull Request + +Be sure to read the [guide](https://github.com/louislam/dockge/blob/master/CONTRIBUTING.md), as we don't accept all types of pull requests and don't want to waste your time. + +## FAQ + +#### "Dockge"? + +"Dockge" is a coinage word which is created by myself. I originally hoped it sounds like `Dodge`, but apparently many people called it `Dockage`, it is also acceptable. + +The naming idea came from Twitch emotes like `sadge`, `bedge` or `wokege`. They all end in `-ge`. + +#### Can I manage a single container without `compose.yaml`? + +The main objective of Dockge is to try to use the docker `compose.yaml` for everything. If you want to manage a single container, you can just use Portainer or Docker CLI. + +#### Can I manage existing stacks? + +Yes, you can. However, you need to move your compose file into the stacks directory: + +1. Stop your stack +2. Move your compose file into `/opt/stacks//compose.yaml` +3. In Dockge, click the " Scan Stacks Folder" button in the top-right corner's dropdown menu +4. Now you should see your stack in the list + +#### Is Dockge a Portainer replacement? + +Yes or no. Portainer provides a lot of Docker features. While Dockge is currently only focusing on docker-compose with a better user interface and better user experience. + +If you want to manage your container with docker-compose only, the answer may be yes. + +If you still need to manage something like docker networks, single containers, the answer may be no. + +#### Can I install both Dockge and Portainer? + +Yes, you can. + +## Others + +Dockge is built on top of [Compose V2](https://docs.docker.com/compose/migrate/). `compose.yaml` also known as `docker-compose.yml`. \ No newline at end of file diff --git a/apps/dockge/data.yml b/apps/dockge/data.yml new file mode 100644 index 00000000..3c2af547 --- /dev/null +++ b/apps/dockge/data.yml @@ -0,0 +1,20 @@ +name: Dockge +tags: + - 工具 +title: 一个精美的、易于使用的、反应式的自托管 docker compose.yaml 面向堆栈的管理器 +type: 工具 +description: 一个精美的、易于使用的、反应式的自托管 docker compose.yaml 面向堆栈的管理器 +additionalProperties: + key: dockge + name: Dockge + tags: + - Tool + shortDescZh: 一个精美的、易于使用的、反应式的自托管 docker compose.yaml 面向堆栈的管理器 + shortDescEn: A fancy, easy-to-use and reactive self-hosted docker compose.yaml stack-oriented manager + type: tool + crossVersionUpdate: true + limit: 0 + recommend: 0 + website: https://dockge.kuma.pet + github: https://github.com/louislam/dockge + document: https://github.com/louislam/dockge diff --git a/apps/dockge/latest/.env.sample b/apps/dockge/latest/.env.sample new file mode 100644 index 00000000..69ba934e --- /dev/null +++ b/apps/dockge/latest/.env.sample @@ -0,0 +1,4 @@ +CONTAINER_NAME="dockge" +PANEL_APP_PORT_HTTP="40186" +DATA_PATH="./data" +STACKS_PATH="/opt/dockge/stacks" diff --git a/apps/dockge/latest/data.yml b/apps/dockge/latest/data.yml new file mode 100644 index 00000000..c0f692e0 --- /dev/null +++ b/apps/dockge/latest/data.yml @@ -0,0 +1,24 @@ +additionalProperties: + formFields: + - default: 40186 + edit: true + envKey: PANEL_APP_PORT_HTTP + labelEn: Port + labelZh: 端口 + required: true + rule: paramPort + type: number + - default: ./data + edit: true + envKey: DATA_PATH + labelEn: Data folder path + labelZh: 数据文件夹路径 + required: true + type: text + - default: /opt/dockge/stacks + edit: true + envKey: STACKS_PATH + labelEn: compose yml folder path (Absolute Path) + labelZh: compose 编排文件路径 (绝对路径) + required: true + type: text diff --git a/apps/dockge/latest/docker-compose.yml b/apps/dockge/latest/docker-compose.yml new file mode 100644 index 00000000..ac4fc8b7 --- /dev/null +++ b/apps/dockge/latest/docker-compose.yml @@ -0,0 +1,23 @@ +version: '3' +services: + dockge: + container_name: ${CONTAINER_NAME} + restart: always + networks: + - 1panel-network + ports: + - "${PANEL_APP_PORT_HTTP}:5001" + volumes: + - /var/run/docker.sock:/var/run/docker.sock + - ${DATA_PATH}:/app/data + - ${STACKS_PATH}:/opt/stacks + # - /root/.docker/:/root/.docker + environment: + - DOCKGE_STACKS_DIR=/opt/stacks + image: louislam/dockge:latest + labels: + createdBy: "Apps" + +networks: + 1panel-network: + external: true diff --git a/apps/dockge/logo.png b/apps/dockge/logo.png new file mode 100644 index 0000000000000000000000000000000000000000..9de2036219c93971c7813d8c1bfa8583064a1345 GIT binary patch literal 3286 zcmZ`*X*3&Zw+=DSrRIhjs{N>WDkZeE=s{IY=c2|2QM5(O^C=xDhc?6*Q>!&pHHMn2 zh9VO4kcc5AB8G?v(i%SB{qDVg?!9}h_t|^x=Xuut@xJR_`-PpY1wW4z4*&q*x3V<1 zKg+0p9WLM*@`&u8Axoc~wZpC5-QBbL4F4TFwEwRD|4gCM|4k14+$U|*oA8I-iw7gC zjQ`Woh(G+Fe$UcD|MJ0)pNz>h#`gaj)G~kAyL>RZy1%@=wX*$RrdGlsdYyt>XEe_r z4pUZ_HuuhmwuOU^g~QoR$_$x--`Z?l-ug;7T-f**br$U_t39jh{p6Ja5@l?CW1jM# z7SdunX{m#_*}b;hxlHRN6VH?_i#t=4%^o6cbYm5TI}GbNZC>7JUfOE;Norc8HZ9N^ z=NVsrt~BEJzpfCQ2)ixImGIFutxX!TJv(hc+Vzx5N8> zMGVj*e(XjJQX_usMEsyd4O1eADN$&04(2GX{{%7iyLyHhHA0H&J*}T(MxoczhK`HJ ze^*TXN*XvpPX79WV`fiMGSJ8M3!5p}^{Qzma(XubO^wB@=8W&W$5G=3_v`WW!kLYC zcnTbQ^n7IRNKZ=P>=s?Z>}~HS1K8t}p8d(=aKqqoREWFk`SiQyU0FbyX}(lmtAg$zP|&*EGHyWHzgr{xpU_vPQSxO-@rz%`&WSW1aKM(jVF&s zAZ91H=lIbgNLcRT#s?nLc&En+lQUI)bs+bdr8@xoA>G-4D;1!iU*-Q;`oY7LPqqFv z7Jv8pj`-D2+LQJcvW$18D5Udpbai>4yFeE7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