Formerly KrillinAI, VideoTranslation and Dubbing Tool for 120+ Languages. Open-source AI workspace for creators, powered by Codex. Video downloader, video translation, create videos, images, audios, and edits with Agents in one place. For your Social Media like YouTube, TikTok, Instagram, etc.
TypeScript agent-skillscodex-clideskop-appdubbingimage-generationlocalizationskillsttsvideo-editingvideo-generationvideo-transcriptionvideo-translation
feat: update dockerfile to support edge-tts
puji481000c8dd5b150b
diff --git a/Dockerfile b/Dockerfileindex 3555da4f..3d6368e9 100644--- a/Dockerfile+++ b/Dockerfile@@ -9,21 +9,25 @@ RUN apt-get update && \RUN mkdir -p bin && \ARCH=$(uname -m) && \case "$ARCH" in \- x86_64) \- URL="https://github.com/yt-dlp/yt-dlp/releases/download/2025.01.15/yt-dlp_linux"; \- ;; \- armv7l) \- URL="https://github.com/yt-dlp/yt-dlp/releases/download/2025.01.15/yt-dlp_linux_armv7l"; \- ;; \- aarch64) \- URL="https://github.com/yt-dlp/yt-dlp/releases/download/2025.01.15/yt-dlp_linux_aarch64"; \- ;; \- *) \- echo "Unsupported architecture: $ARCH" && exit 1; \- ;; \+ x86_64) \+ YT_DLP_URL="https://github.com/yt-dlp/yt-dlp/releases/download/2025.01.15/yt-dlp_linux"; \+ EDGE_TTS_URL="https://github.com/puji4810/edge-tts-pkg/releases/download/v0.0.1/edge-tts-linux"; \+ ;; \+ armv7l) \+ YT_DLP_URL="https://github.com/yt-dlp/yt-dlp/releases/download/2025.01.15/yt-dlp_linux_armv7l"; \+ EDGE_TTS_URL="https://github.com/puji4810/edge-tts-pkg/releases/download/v0.0.1/edge-tts-linux"; \+ ;; \+ aarch64) \+ YT_DLP_URL="https://github.com/yt-dlp/yt-dlp/releases/download/2025.01.15/yt-dlp_linux_aarch64"; \+ EDGE_TTS_URL="https://github.com/puji4810/edge-tts-pkg/releases/download/v0.0.1/edge-tts-linux"; \+ ;; \+ *) \+ echo "Unsupported architecture: $ARCH" && exit 1; \+ ;; \esac && \- wget -O bin/yt-dlp "$URL" && \- chmod +x bin/yt-dlp+ wget -O bin/yt-dlp "$YT_DLP_URL" && \+ wget -O bin/edge-tts "$EDGE_TTS_URL" && \+ chmod +x bin/yt-dlp bin/edge-ttsCOPY KlicStudio ./diff --git a/config/config-example.toml b/config/config-example.tomlindex ff94ea60..2c7bee43 100644--- a/config/config-example.toml+++ b/config/config-example.toml@@ -21,6 +21,7 @@[transcribe] # 视频转文本支持多种方案,配置时先填provider,再填对应的配置provider = "openai" #语音识别,当前可选值:openai,fasterwhisper,whisperkit,whisper.cpp,aliyun。(fasterwhisper不支持macOS,whisperkit只支持M芯片)+ enable_gpu_acceleration = false # 给fasterwhisper进行GPU加速选项,50系显卡请务必开启,否则无法正常运行[transcribe.openai]base_url = ""api_key = ""@@ -42,7 +43,7 @@app_key= ""[tts]- provider = "aliyun" # 可选值:openai,aliyun+ provider = "aliyun" # 可选值:openai,aliyun,edge-tts[tts.openai]base_url = ""api_key = ""diff --git a/internal/deps/checker.go b/internal/deps/checker.goindex e7e37ace..a2c3563c 100644--- a/internal/deps/checker.go+++ b/internal/deps/checker.go@@ -591,9 +591,23 @@ func checkEdgeTts() error {if runtime.GOOS == "windows" {downloadUrl = "https://github.com/puji4810/edge-tts-pkg/releases/download/v0.0.1/edge-tts-windows.exe"} else if runtime.GOOS == "linux" {- downloadUrl = "https://github.com/puji4810/edge-tts-pkg/releases/download/v0.0.1/edge-tts-linux"+ if runtime.GOARCH == "amd64" {+ downloadUrl = "https://github.com/puji4810/edge-tts-pkg/releases/download/v0.0.1/edge-tts-linux-amd64"+ } else if runtime.GOARCH == "arm64" {+ downloadUrl = "https://github.com/puji4810/edge-tts-pkg/releases/download/v0.0.1/edge-tts-linux-arm64"+ } else {+ log.GetLogger().Error("不支持你当前的操作系统", zap.String("当前系统", runtime.GOOS))+ return fmt.Errorf("unsupported OS: %s", runtime.GOOS)+ }} else if runtime.GOOS == "darwin" {- downloadUrl = "https://github.com/puji4810/edge-tts-pkg/releases/download/v0.0.1/edge-tts-macos"+ if runtime.GOARCH == "amd64" {+ downloadUrl = "https://github.com/puji4810/edge-tts-pkg/releases/download/v0.0.1/edge-tts-macos-intel"+ } else if runtime.GOARCH == "arm64" {+ downloadUrl = "https://github.com/puji4810/edge-tts-pkg/releases/download/v0.0.1/edge-tts-macos-apple"+ } else {+ log.GetLogger().Error("不支持你当前的操作系统", zap.String("当前系统", runtime.GOOS))+ return fmt.Errorf("unsupported OS: %s", runtime.GOOS)+ }}else {log.GetLogger().Error("不支持你当前的操作系统", zap.String("当前系统", runtime.GOOS))return fmt.Errorf("unsupported OS: %s", runtime.GOOS)