feat:添加headscale-derp到列表

This commit is contained in:
okxlin 2023-12-13 23:06:03 +08:00
parent b4f16b898a
commit 5f1a9d0d6b
8 changed files with 148 additions and 0 deletions

View File

@ -0,0 +1,28 @@
# Derper
[![docker workflow](https://github.com/fredliang44/derper-docker/actions/workflows/docker-image.yml/badge.svg)](https://hub.docker.com/r/fredliang/derper)
[![docker pulls](https://img.shields.io/docker/pulls/fredliang/derper.svg?color=brightgreen)](https://hub.docker.com/r/fredliang/derper)
[![platfrom](https://img.shields.io/badge/platform-amd64%20%7C%20arm64-brightgreen)](https://hub.docker.com/r/fredliang/derper/tags)
# Setup
> required: set env `DERP_DOMAIN` to your domain
```bash
docker run -e DERP_DOMAIN=derper.your-domain.com -p 80:80 -p 443:443 -p 3478:3478/udp fredliang/derper
```
| env | required | description | default value |
| ------------------- | -------- | ---------------------------------------------------------------------- | ----------------- |
| DERP_DOMAIN | true | derper server hostname | your-hostname.com |
| DERP_CERT_DIR | false | directory to store LetsEncrypt certs(if addr's port is :443) | /app/certs |
| DERP_CERT_MODE | false | mode for getting a cert. possible options: manual, letsencrypt | letsencrypt |
| DERP_ADDR | false | listening server address | :443 |
| DERP_STUN | false | also run a STUN server | true |
| DERP_STUN_PORT | false | The UDP port on which to serve STUN. | 3478 |
| DERP_HTTP_PORT | false | The port on which to serve HTTP. Set to -1 to disable | 80 |
| DERP_VERIFY_CLIENTS | false | verify clients to this DERP server through a local tailscaled instance | false |
# Usage
Fully DERP setup offical documentation: https://tailscale.com/kb/1118/custom-derp-servers/

View File

@ -0,0 +1,20 @@
name: Headscale-DERP
tags:
- 工具
title: Headscale 的中继服务
type: 工具
description: Headscale 的中继服务
additionalProperties:
key: headscale-derp
name: Headscale-DERP
tags:
- Tool
shortDescZh: Headscale 的中继服务
shortDescEn: Headscale relay service
type: tool
crossVersionUpdate: true
limit: 0
recommend: 0
website: https://hub.docker.com/r/fredliang/derper
github: https://github.com/fredliang44/derper-docker
document: https://headscale.net

View File

@ -0,0 +1,5 @@
CONTAINER_NAME="headscale-derp"
PANEL_APP_PORT_HTTPS="40184"
PANEL_APP_PORT_STUN="3478"
DATA_PATH="./data"
DERP_DOMAIN="derper.your-domain.com"

View File

@ -0,0 +1,32 @@
additionalProperties:
formFields:
- default: 40184
edit: true
envKey: PANEL_APP_PORT_HTTPS
labelEn: Port
labelZh: 端口
required: true
rule: paramPort
type: number
- default: 3478
edit: true
envKey: PANEL_APP_PORT_STUN
labelEn: STUN Service Port
labelZh: STUN 服务端口
required: true
rule: paramPort
type: number
- default: ./data
edit: true
envKey: DATA_PATH
labelEn: Data folder path (Domain certificate needs to be replaced, certificate file name is the same as the server hostname)
labelZh: 数据文件夹路径 (需要替换域名证书,证书文件名与服务器主机名相同)
required: true
type: text
- default: 'derper.your-domain.com'
edit: true
envKey: DERP_DOMAIN
labelEn: Derper server hostname
labelZh: Derper服务器主机名
required: true
type: text

View File

@ -0,0 +1,30 @@
-----BEGIN CERTIFICATE-----
MIICTzCCAfWgAwIBAgIUVimWHYcwGCEzjo2PIWRX+pk5xk4wCgYIKoZIzj0EAwIw
czELMAkGA1UEBhMCVVMxEzARBgNVBAgMCkNhbGlmb3JuaWExFDASBgNVBAcMC0xv
cyBBbmdlbGVzMRgwFgYDVQQKDA9NeSBPcmdhbml6YXRpb24xHzAdBgNVBAMMFmRl
cnBlci55b3VyLWRvbWFpbi5jb20wIBcNMjMxMjEzMTMzMTM1WhgPMjEyMzExMTkx
MzMxMzVaMHMxCzAJBgNVBAYTAlVTMRMwEQYDVQQIDApDYWxpZm9ybmlhMRQwEgYD
VQQHDAtMb3MgQW5nZWxlczEYMBYGA1UECgwPTXkgT3JnYW5pemF0aW9uMR8wHQYD
VQQDDBZkZXJwZXIueW91ci1kb21haW4uY29tMFkwEwYHKoZIzj0CAQYIKoZIzj0D
AQcDQgAEuQsY4F6ixzijQoNJ5qhRwiXIQVRi8/4+ARi9y2XDqno+mRTe6kcqbWza
o1Qvnb+bDQX3TlI0znR07/TBbnKm3KNlMGMwIQYD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END CERTIFICATE-----

View File

@ -0,0 +1,5 @@
-----BEGIN PRIVATE KEY-----
MIGHAgEAMBMGByqGSM49AgEGCCqGSM49AwEHBG0wawIBAQQgFMO2b7macGU9gXYD
NNVXS+NaDgVBT7chDLvRckGHNUmhRANCAAS5CxjgXqLHOKNCg0nmqFHCJchBVGLz
/j4BGL3LZcOqej6ZFN7qRyptbNqjVC+dv5sNBfdOUjTOdHTv9MFucqbc
-----END PRIVATE KEY-----

View File

@ -0,0 +1,28 @@
version: '3'
services:
headscale-derp:
container_name: ${CONTAINER_NAME}
restart: always
networks:
- 1panel-network
ports:
- "${PANEL_APP_PORT_HTTPS}:${PANEL_APP_PORT_HTTPS}"
- "${PANEL_APP_PORT_STUN}:${PANEL_APP_PORT_STUN}/udp"
volumes:
- "${DATA_PATH}:/app/certs"
environment:
- DERP_DOMAIN=${DERP_DOMAIN}
- DERP_CERT_MODE=manual
- DERP_ADDR=:${PANEL_APP_PORT_HTTPS}
- DERP_HTTP_PORT=-1
- DERP_STUN=true
- DERP_STUN_PORT=${PANEL_APP_PORT_STUN}
- DERP_CERT_DIR=/app/certs
- DERP_VERIFY_CLIENTS=false
image: fredliang/derper:latest
labels:
createdBy: "Apps"
networks:
1panel-network:
external: true

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB