1
0
mirror of https://github.com/pooneyy/1Panel-Appstore.git synced 2026-03-27 16:35:55 +08:00

feat(squid): add squid proxy server application package

- add squid 7.5 version configuration with data.yml for form fields and internationalization
- add docker-compose.yml for container deployment with environment variable mapping
- add README.md and README_en.md with detailed product introduction and usage instructions
- add main application data.yml with metadata, tags, and supported architectures
- add logo.png for application branding
This commit is contained in:
pooneyy 2026-03-22 18:56:19 +08:00
parent 8d1ba8c938
commit 86b69e4a55
No known key found for this signature in database
6 changed files with 256 additions and 0 deletions

117
apps/squid/7.5.0/data.yml Normal file
View File

@ -0,0 +1,117 @@
additionalProperties:
formFields:
- default: Only use the following configuration items to create the configuration file if it does not exist. For existing configuration files, please edit them manually and then restart the application.
envKey: NOTE
labelZh: 注意
labelEn: Note
label:
zh: 注意
zh-Hant: 注意
en: Note
ja: 注意
ko: 주의
ms: Perhatian
pt-br: Atenção
ru: Внимание
tr: Not
description:
zh: 仅在配置文件不存在时使用以下配置项创建配置文件,已经存在的配置文件,请手动编辑,然后重启应用。
zh-Hant: 僅在設定檔不存在時使用以下設定項建立設定檔,已經存在的設定檔,請手動編輯,然後重新啟動應用程式。
en: Only use the following configuration items to create the configuration file if it does not exist. For existing configuration files, please edit them manually and then restart the application.
ja: 設定ファイルが存在しない場合のみ、以下の設定項目を使用して設定ファイルを作成してください。既存の設定ファイルは手動で編集し、その後アプリケーションを再起動してください。
ko: 설정 파일이 없는 경우에만 다음 설정 항목을 사용하여 설정 파일을 생성하십시오. 기존 설정 파일은 수동으로 편집한 후 애플리케이션을 다시 시작하십시오.
ms: Hanya gunakan item konfigurasi berikut untuk mencipta fail konfigurasi jika ia tidak wujud. Untuk fail konfigurasi yang sedia ada, sila edit secara manual dan kemudian mulakan semula aplikasi.
pt-br: Use os seguintes itens de configuração apenas para criar o arquivo de configuração se ele não existir. Para arquivos de configuração existentes, edite-os manualmente e, em seguida, reinicie o aplicativo.
ru: Используйте следующие параметры конфигурации для создания файла конфигурации, только если он не существует. Для существующих файлов конфигурации отредактируйте их вручную, а затем перезапустите приложение.
tr: Yalnızca yapılandırma dosyası mevcut değilse, aşağıdaki yapılandırma öğelerini kullanarak dosyayı oluşturun. Mevcut yapılandırma dosyaları için lütfen manuel olarak düzenleyin ve ardından uygulamayı yeniden başlatın.
required: false
type: text
disabled: true
- default: 3128
envKey: PANEL_APP_PORT_HTTP
labelZh: 代理服务器连接端口
labelEn: Proxy Server Connection Port
label:
zh: 代理服务器连接端口
zh-Hant: 代理伺服器連線埠
en: Proxy Server Connection Port
ja: プロキシサーバー接続ポート
ko: 프록시 서버 연결 포트
ms: Port Sambungan Pelayan Proksi
pt-br: Porta de Conexão do Servidor Proxy
ru: Порт подключения прокси-сервера
tr: Proxy Sunucusu Bağlantı Noktası
description:
zh: "设置代理服务器的连接端口,有效范围: 1-65535"
zh-Hant: "設定代理伺服器的連接埠,有效範圍: 1-65535"
en: "Set the connection port for the proxy server. Valid range: 1-65535"
ja: "プロキシサーバーの接続ポートを設定します。有効範囲: 1-65535"
ko: "프록시 서버의 연결 포트를 설정합니다. 유효 범위: 1-65535"
ms: "Tetapkan port sambungan untuk pelayan proksi. Julat sah: 1-65535"
pt-br: "Defina a porta de conexão para o servidor proxy. Intervalo válido: 1-65535"
ru: "Установите порт подключения для прокси-сервера. Допустимый диапазон: 1-65535"
tr: "Proxy sunucusu için bağlantı noktasını ayarlayın. Geçerli aralık: 1-65535"
required: true
type: number
edit: true
rule: paramPort
- default: squid_user
envKey: SQUID_AUTH_USER
labelZh: 代理服务器用户名
labelEn: Proxy Server Username
label:
zh: 代理服务器用户名
zh-Hant: 代理伺服器使用者名稱
en: Proxy Server Username
ja: プロキシサーバーユーザー名
ko: 프록시 서버 사용자 이름
ms: Nama Pengguna Pelayan Proksi
pt-br: Nome de Usuário do Servidor Proxy
ru: Имя пользователя прокси-сервера
tr: Proxy Sunucusu Kullanıcı Adı
required: false
type: text
edit: true
rule: paramCommon
random: true
- default: squid_pass
envKey: SQUID_AUTH_PASS
labelZh: 代理服务器密码
labelEn: Proxy Server Password
label:
zh: 代理服务器密码
zh-Hant: 代理伺服器密碼
en: Proxy Server Password
ja: プロキシサーバーパスワード
ko: 프록시 서버 비밀번호
ms: Kata Laluan Pelayan Proksi
pt-br: Senha do Servidor Proxy
ru: Пароль прокси-сервера
tr: Proxy Sunucusu Parolası
required: false
type: password
edit: true
rule: paramComplexity
random: true
- default: "true"
envKey: SQUID_ONLY_HTTPS
labelZh: 仅使用 HTTP/HTTPS
labelEn: Use HTTP/HTTPS only
label:
zh: 仅使用 HTTP/HTTPS
zh-Hant: 僅使用 HTTP/HTTPS
en: Use HTTP/HTTPS only
ja: HTTP/HTTPS のみを使用
ko: HTTP/HTTPS만 사용
ms: Gunakan HTTP/HTTPS sahaja
pt-br: Usar apenas HTTP/HTTPS
ru: Использовать только HTTP/HTTPS
tr: Yalnızca HTTP/HTTPS kullan
required: false
type: select
edit: true
values:
- label: Only HTTPS
value: "true"
- label: Only HTTP
value: "false"

View File

@ -0,0 +1,22 @@
services:
squid:
image: ghcr.io/pooneyy/squid:7.5
container_name: ${CONTAINER_NAME}
ports:
- ${PANEL_APP_PORT_HTTP}:3128
volumes:
- /etc/localtime:/etc/localtime:ro
- ./conf:/etc/squid
- ./cert:/etc/squid-ssl
- ./logs:/var/log/squid
environment:
SQUID_AUTH_USER: ${SQUID_AUTH_USER}
SQUID_AUTH_PASS: ${SQUID_AUTH_PASS}
SQUID_ONLY_HTTPS: ${SQUID_ONLY_HTTPS}
networks:
- 1panel-network
labels:
createdBy: Apps
networks:
1panel-network:
external: true

41
apps/squid/README.md Normal file
View File

@ -0,0 +1,41 @@
## 产品介绍
Squid是一个开源的代理服务器支持HTTP、HTTPS等多种协议。Squid提供广泛的访问控制和安全功能适用于互联网服务提供商、企业网络等场景。
## 主要功能
- **Web内容缓存与加速**:通过缓存频繁访问的网页内容,显著减少带宽使用并提高客户端响应速度,有效降低服务器负载,提升网站内容分发效率。
- **多协议代理支持**全面支持HTTP、HTTPS、FTP等主流网络协议并可扩展支持ICAP、eCAP等扩展协议满足多样化的代理需求。
- **访问控制与安全策略**提供灵活的访问控制列表ACL和安全策略配置可用于内容过滤、用户认证、流量管理和网络安全防护。
- **负载均衡与服务器加速**:支持构建缓存层次结构和内容集群,实现智能请求路由和负载均衡,可作为服务器加速器提升整体系统性能。
- **跨平台运行与高可扩展性**可在Windows、Linux、macOS等多种操作系统上运行支持通过插件、认证模块和扩展接口增强功能适应不同部署环境。
## 配置和使用说明
1. 安装应用时请勾选**端口外部访问**。
2. 容器会在启动时根据环境变量创建配置文件,已经存在的配置文件不会被覆盖,修改配置文件后重启容器生效。
3. 配置 HTTPS 代理需要 SSL 证书。容器首次启动时会创建一对有效期为 100 年的自签名 X.509 证书和私钥,建议后期使用从受信任的 CA 签发的服务器 IP 证书替代。
- 证书保存为 `应用文件夹/cert/squid.crt`
- 私钥保存为 `应用文件夹/cert/squid.key`
替换证书后重启容器生效。
4. 添加/移除账户
进入容器后,执行以下命令添加账户
```bash
htpasswd -b /etc/squid/passwd <user> <password>
```
进入容器后,执行以下命令移除账户
```bash
htpasswd -D /etc/squid/passwd <user>
```
5. 测试代理服务器的连接
```bash
curl --proxy-insecure -vk -x https://<proxy-server-ip>:<proxy-port> -U <username>:<password> https://httpbin.org/get
```

41
apps/squid/README_en.md Normal file
View File

@ -0,0 +1,41 @@
## Introduction
Squid is an open-source proxy server that supports protocols such as HTTP and HTTPS. It offers extensive access control and security features, making it suitable for scenarios such as internet service providers and corporate networks.
## Features
- **Web Content Caching and Acceleration:** By caching frequently accessed web content, it significantly reduces bandwidth usage and improves client response speed, effectively lowering server load and enhancing content distribution efficiency.
- **Multi-Protocol Proxy Support:** Provides comprehensive support for mainstream network protocols such as HTTP, HTTPS, and FTP, with extensible support for protocols like ICAP and eCAP to meet diverse proxy requirements.
- **Access Control and Security Policies:** Offers flexible Access Control Lists (ACLs) and security policy configurations for content filtering, user authentication, traffic management, and network security protection.
- **Load Balancing and Server Acceleration:** Supports the construction of cache hierarchies and content clusters to enable intelligent request routing and load balancing, serving as a server accelerator to improve overall system performance.
- **Cross-Platform Operation and High Scalability:** Can run on various operating systems including Windows, Linux, and macOS, with support for enhanced functionality through plugins, authentication modules, and extension interfaces to adapt to different deployment environments.
## Configuration and Usage Instructions
1. Please enable **External access** when installing the application.
2. The container will create configuration files based on environment variables at startup. Existing configuration files will not be overwritten. Restart the container for any configuration changes to take effect.
3. Configuring an HTTPS proxy requires an SSL certificate. When the container starts for the first time, it will generate a selfsigned X.509 certificate and private key with a validity period of 100 years. It is recommended to replace it with a server IP certificate issued by a trusted CA later.
- The certificate is stored as `app folder/cert/squid.crt`.
- The private key is stored as `app folder/cert/squid.key`.
Restart the container after replacing the certificate for the changes to take effect.
4. Add/Remove Accounts
After entering the container, execute the following command to add an account:
```bash
htpasswd -b /etc/squid/passwd <user> <password>
```
After entering the container, execute the following command to remove an account:
```bash
htpasswd -D /etc/squid/passwd <user>
```
5. Test the proxy server connection:
```bash
curl --proxy-insecure -vk -x https://<proxy-server-ip>:<proxy-port> -U <username>:<password> https://httpbin.org/get
```

35
apps/squid/data.yml Normal file
View File

@ -0,0 +1,35 @@
name: Squid
tags:
- 实用工具
title: 开源的 Web 代理服务器
description: 开源的 Web 代理服务器
additionalProperties:
key: squid
name: Squid
tags:
- Tool
shortDescZh: 开源的 Web 代理服务器
shortDescEn: Open-source Web Proxy Server
description:
en: Open-source Web Proxy Server
zh: 开源的 Web 代理服务器
zh-Hant: 開源的 Web 代理伺服器
ja: オープンソースのWebプロキシサーバー
ms: Pelayan Proksi Web Sumber Terbuka
pt-br: Servidor Proxy Web de Código Aberto
ru: Веб-прокси-сервер с открытым исходным кодом
ko: 오픈소스 웹 프록시 서버
type: tool
crossVersionUpdate: true
limit: 0
batchInstallSupport: true
website: https://www.squid-cache.org/
github: https://github.com/squid-cache/squid
document: https://www.squid-cache.org/Doc
architectures:
- amd64
- arm64
- arm/v7
- ppc64le
- riscv64
- s390x

BIN
apps/squid/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB