本站面向开发者与科研用户,提供开源镜像的搜索和下载加速服务。
所有镜像均来源于原始开源仓库,本站不存储、不修改、不传播任何镜像内容。

standalone-firefox Docker 镜像下载 - 轩辕镜像

standalone-firefox 镜像详细信息和使用指南

standalone-firefox 镜像标签列表和版本信息

standalone-firefox 镜像拉取命令和加速下载

standalone-firefox 镜像使用说明和配置指南

Docker 镜像加速服务 - 轩辕镜像平台

国内开发者首选的 Docker 镜像加速平台

极速拉取 Docker 镜像服务

相关 Docker 镜像推荐

热门 Docker 镜像下载

standalone-firefox
selenium/standalone-firefox
自动构建

standalone-firefox 镜像详细信息

standalone-firefox 镜像标签列表

standalone-firefox 镜像使用说明

standalone-firefox 镜像拉取命令

Docker 镜像加速服务

轩辕镜像平台优势

镜像下载指南

相关 Docker 镜像推荐

Selenium网格独立模式镜像,集成Firefox浏览器,用于分布式Web自动化测试,支持单节点简化部署。
196 收藏0 次下载activeselenium镜像

standalone-firefox 镜像详细说明

standalone-firefox 使用指南

standalone-firefox 配置说明

standalone-firefox 官方文档

selenium/standalone-firefox 镜像文档

镜像概述和主要用途

本镜像提供集成Firefox浏览器的Selenium Grid Standalone环境,用于实现WebDriver测试的远程执行。通过该镜像,用户可在隔离容器中部署包含Firefox浏览器的Selenium Grid节点,支持远程提交和运行Web自动化测试任务。

核心功能和特性

  • 集成完整测试环境:内置Firefox浏览器、GeckoDriver(Firefox对应的WebDriver实现)及Selenium Grid Standalone服务,开箱即用。
  • 远程WebDriver支持:通过Selenium Grid协议接收并执行远程WebDriver测试请求,兼容标准Selenium API。
  • 可视化操作监控:提供VNC服务(默认端口7900),支持实时查看容器内Firefox浏览器的操作界面。
  • 灵活的资源配置:支持通过--shm-size参数配置共享内存,优化浏览器运行性能。
  • 版本化标签管理:提供多维度标签体系,可精确指定Selenium Grid版本、Firefox版本、GeckoDriver版本及发布日期。

使用场景和适用范围

  • 自动化测试执行:适用于开发或测试人员在本地或CI/CD环境中远程运行基于Firefox的Selenium WebDriver测试。
  • 隔离环境测试:为Web应用测试提供独立、一致的Firefox浏览器环境,避免本地环境差异影响测试结果。
  • CI/CD流程集成:可嵌入Jenkins、GitHub Actions等CI/CD工具,实现自动化测试环节的容器化部署。
  • 浏览器兼容性验证:通过指定不同Firefox版本的镜像标签,验证Web应用在特定浏览器版本下的兼容性。

使用方法和配置说明

快速启动

通过以下命令启动包含Firefox的Selenium Grid Standalone容器:

bash
docker run -d -p 4444:4444 -p 7900:7900 --shm-size="2g" selenium/standalone-firefox:latest

启动后,将WebDriver测试目标指向http://localhost:4444即可执行远程测试。

端口说明

  • 4444/tcp:Selenium Grid服务端口,用于接收远程WebDriver测试请求(必须映射)。
  • 7900/tcp:VNC服务端口,用于访问容器内Firefox的可视化界面(可选映射,便于调试)。

共享内存配置

运行包含浏览器的镜像时,需通过--shm-size参数配置主机共享内存(推荐2g),避免因容器内共享内存不足导致浏览器崩溃。示例中--shm-size="2g"为强制推荐配置。

VNC访问

若需查看容器内Firefox的实时操作,可通过浏览器访问VNC界面:

http://localhost:7900/?autoconnect=1&resize=scale&password=secret
  • autoconnect=1:自动连接VNC会话;
  • resize=scale:自适应窗口缩放;
  • password=secret:默认VNC密码(固定为secret)。

标签选择

镜像标签支持多维度版本指定,推荐使用完整标签以固定环境版本。标签结构及示例如下:

基础标签结构

selenium/standalone-firefox-<Major>.<Minor>.<Patch>-<YYYYMMDD>
  • <Major>.<Minor>.<Patch>:Selenium Grid版本;
  • <YYYYMMDD>:发布日期(如20230426表示2023年4月26日)。

含浏览器及驱动版本的标签结构

selenium/standalone-firefox-<browserVersion>-<browserDriver>-<browserDriverVersion>-<Major>.<Minor>.<Patch>-<YYYYMMDD>
  • <browserVersion>:Firefox浏览器版本(如110.0);
  • <browserDriver>:驱动名称(固定为geckodriver);
  • <browserDriverVersion>:GeckoDriver版本(如0.33.0)。

标签示例(以Firefox 110.0、GeckoDriver 0.33.0、Selenium Grid 4.9.0、发布日期20230426为例)

标签格式说明
4最新Selenium Grid 4.x版本
4.9最新Selenium Grid 4.9.x版本
4.9.0固定Selenium Grid 4.9.0版本
4.9.0-20230426固定Selenium Grid 4.9.0及20230426发布版本
110.0固定Firefox 110.0版本
110.0-20230426固定Firefox 110.0及20230426发布版本
110.0-geckodriver-0.33.0固定Firefox 110.0及GeckoDriver 0.33.0
110.0-geckodriver-0.33.0-20230426固定Firefox 110.0、GeckoDriver 0.33.0及20230426发布版本
110.0-geckodriver-0.33.0-grid-4.9.0-20230426完整版本锁定(浏览器、驱动、Grid版本及发布日期)

Docker 部署示例

docker run 命令

基础部署(使用最新版本):

bash
docker run -d \
  -p 4444:4444 \  # Grid服务端口
  -p 7900:7900 \  # VNC访问端口
  --shm-size="2g" \  # 共享内存配置
  selenium/standalone-firefox:latest

版本锁定部署(指定Firefox 110.0、GeckoDriver 0.33.0、Grid 4.9.0):

bash
docker run -d \
  -p 4444:4444 \
  -p 7900:7900 \
  --shm-size="2g" \
  selenium/standalone-firefox:110.0-geckodriver-0.33.0-grid-4.9.0-20230426

docker-compose 配置

创建docker-compose.yml文件,定义单节点部署:

yaml
version: '3.8'
services:
  selenium-firefox:
    image: selenium/standalone-firefox:110.0-geckodriver-0.33.0-grid-4.9.0-20230426
    ports:
      - "4444:4444"   # Grid服务端口
      - "7900:7900"   # VNC访问端口
    shm_size: "2g"    # 共享内存配置
    restart: unless-stopped  # 容器退出时自动重启(除非手动停止)

启动命令:docker-compose up -d

完整文档和资源

  • 项目详细文档:Docker-Selenium GitHub README
  • Selenium Grid***文档:Selenium Grid Getting Started
  • 标签命名规范:Docker-Selenium Tagging Convention

许可证

本项目源代码基于Apache License 2.0开源协议发布,允许自由使用、修改和分发。

用户好评

来自真实用户的反馈,见证轩辕镜像的优质服务

oldzhang的头像

oldzhang

运维工程师

Linux服务器

5

"Docker加速体验非常流畅,大镜像也能快速完成下载。"