专属域名
文档搜索
轩辕助手
Run助手
邀请有礼
返回顶部
快速返回页面顶部
收起
收起工具栏
轩辕镜像 官方专业版
轩辕镜像 官方专业版轩辕镜像 官方专业版官方专业版
首页个人中心搜索镜像

交易
充值流量我的订单
工具
提交工单镜像收录一键安装
Npm 源Pip 源Homebrew 源
帮助
常见问题
其他
关于我们网站地图

官方QQ群: 1072982923

lucasgaitzsch/pdf-turtle Docker 镜像 - 轩辕镜像 | Docker 镜像高效稳定拉取服务

热门搜索:openclaw🔥nginx🔥redis🔥mysqlopenjdkcursorweb2apimemgraphzabbixetcdubuntucorednsjdk
pdf-turtle
lucasgaitzsch/pdf-turtle
lucasgaitzsch
A painless html to pdf rendering service
2 次收藏下载次数: 0状态:社区镜像维护者:lucasgaitzsch仓库类型:镜像最近更新:21 天前
轩辕镜像,不浪费每一次拉取。点击查看
镜像简介版本下载
轩辕镜像,不浪费每一次拉取。点击查看

PdfTurtle 🐢 HTML to PDF generation service

![build and test]([] ![Go Report Card]([] ![codecov]([] ![Maintainability Rating]([] ![Reliability Rating]([] ![Security Rating]([] ![Lines of Code]([] ![Docker Pulls]([]

A painless html to pdf rendering service

PdfTurtle generates PDF reports and documents from HTML templates or raw HTML.

Try it! Here's a DEMO__🐢__.

!Screenshot

🎢 Features

  • ✅ Free, OpenSource and Self-Hosted
  • 💬 Generate PDFs in a descriptive way from HTML and CSS (with JavaScript support)
  • ✨ Supports modern HTML and CSS standards (uses latest Chromium engine)
  • 👻 Builtin template engines (go-template, raymond and django)
  • 💼 Bundle template and assets in ZIP file (see Bundle workflow)
  • 🚀 Fast generation with limited resources (limited multithreading)
  • 🔥 Multiple replicas supported (stateless service design)
  • 🖥 Frontend (Playground) for rapid development
  • 💫 Beautiful fonts included and preoptimized style (CSS) for PDF or print
  • 📦 Container image available (see Run with docker)

💥 How to run the service

With docker container (recommended)

The container image is available on Docker Hub.

With the tag *-playground you get a bundled image with the web playground.

bash
docker pull lucasgaitzsch/pdf-turtle

docker run -d \
    -p 8000:8000 \
    --name pdf-turtle \
    --restart unless-stopped \
    lucasgaitzsch/pdf-turtle

Included fonts:

  • Open Sans
  • Roboto
  • Noto Emoji
Config
command line argumentenvironment variabletypedefaultdescription
--help---Show help
--logDebugLOG_LEVEL_DEBUGbooleanfalseDebug log level active
--logJsonOutputLOG_JSON_OUTPUTbooleanfalseJson log output
--renderTimeoutRENDER_TIMEOUTinteger30Render timeout in seconds
--workerInstancesWORKER_INSTANCESinteger30Count of worker instances
--portPORTinteger8000Server port
--maxBodySizeMAX_BODY_SIZEinteger32Max body size in megabyte
--servePlaygroundSERVE_PLAYGROUNDbooleanfalseServe playground from path "./static-files/playground/"
--secretSECRETstring""Secret used as bearer token

🚀 How to use

Bundle Workflow (recommended)
mermaid
flowchart LR
    subgraph PG[PdfTurtle-Playground]
        direction LR
        O(go to<br>pdfturtle.gaitzsch.dev) --> |go to model tab| MO(paste an<br> example model)
        click O href "[***]" "[***]"
        O --> |go to body tab| B(design the body)
        O --> |go to header tab| H(design the header)
        O --> |go to footer tab| F(design the footer)
        O --> |go in asstes menu| A(put your assets)

        OPT(set your<br> options)
        MO --> OPT
        B --> OPT
        H --> OPT
        F --> OPT
        A --> OPT
        OPT --> S(fa:fa-file-zipper save as<br> ZIP bundle)
    end

    subgraph YP[your fancy project]
        direction TB
        PA(provide as asset)
        PA-->CL(use clent lib)
        PA-->SGC(use swagger to<br> build or generate client)
        R(render PDF with<br> bundle and your model)
        CL-->R
        SGC-->R
        R-->BH(fa:fa-smile be happy!)
    end

    S-->|copy zip bundle<br> to your project|YP
    %%PG-->YP
1. Prepare project

Choose the fitting client lib for your language or generate / build your own by the OpenApi (Swagger) description.

2. Design your PDF in the playground

Go to 🐢PdfTurtle-Playground, put an example model as JSON and design your PDF. Download the bundle as ZIP file and put it in your resources/assets.

!PdfTurtleBundle-Workflow

3. Call the service with the client and your data

Send a request to a PdfTurtle instance with your bundle and your model. You will get a rendered PDF.

And thats it.

Hint: You can split your bundle

If you want to have the same header for all documents, you can create a ZIP file with with only the header.html and the required assets. Now you can call the Service with multiple bundle files. The service will assemble the files together. Single files can be send as bundle-component without compressing to a ZIP file. All files with other names than "index.html", "header.html", "footer.html" and "options.json" will be put to the folder "/assets/".

PdfTurtle Playground

You can write and test templates with the builtin playground.

Client libs
  • 📦 .NET Standard 2.0 (.NET Core 2.0+ & .NET Framework 4.6.1+) Client
  • 📦 Golang (Go) Client
Swagger

Use Swagger-UI under /swagger/index.html as API documentation.

You can use the swagger description (/swagger/doc.json or ./server/docs/swagger.json) to generate a API client for the language of your choice.

Postman

You can import the swagger file to test the service with Postman or an alternative.

Included template engines

Template stylePackagePdfTurtle keyURL
Golanghtml/templategolang[***]
Django-syntax like (require model. prefix)pongo2django[***]
Handlebars-syntax likeraymondhandlebars[***]
Included template functions
Function nameParametersDescription
marshalobjectEncodes provided object as JSON string
barcodeQrcontentRenders a SVG QR code from content
barcodeEancontentRenders a SVG EAN code from content
strContainshaystack, needleDoes the haystack contains the needle
strHasPrefixhaystack, needleDoes the first string starts with the second
strHasSuffixhaystack, needleDoes the first string end with the second
addfloat64, float64Adds two float64 numbers
subtractfloat64, float64Subtracts two float64 numbers
multiplyfloat64, float64Multiplies two float64 numbers
dividefloat64, float64Divides two float64 numbers
float64ToIntfloat64Convert a int to float64
intToFloat64intConvert a float64 to int
bitwiseAndint, inta & b

Development / Build from source

See README_DEV.md.

🚧 Roadmap

  • Bundle/Package support for exchangeable templates
  • Client libs
    • .NET Standard 2.0 (.NET Core 2.0+ & .NET Framework 4.6.1+)
    • Golang
    • Kotlin, Java (JVM languages)
    • ..?
  • Markdown to PDF
  • Preload and cache JavaScript libs

🔨 Contribution

Contributors are welcome! Feel you free to fork the project and open a pull request.

If you wrote a client lib for a uncovered language please contact me. I will create a repo for you or link your client lib in this readme file.

☢ Build with

  • go
  • chromedp (golang chromium driver)
  • goquery
  • chromium (render engine)
  • raymond (handlebars template engine)
  • pongo2 (django template engine)
  • zerolog
  • go-arg
  • barcode and svgo
查看更多 pdf-turtle 相关镜像 →
rancher/turtles logo
rancher/turtles
rancher
暂无描述
10万+ 次下载
3 天前更新
galaxyxieyu/eggturtles logo
galaxyxieyu/eggturtles
galaxyxieyu
暂无描述
1万+ 次下载
1 小时前更新
xturtle/consul logo
xturtle/consul
xturtle
暂无描述
755 次下载
4 年前更新
xturtle/logstash logo
xturtle/logstash
xturtle
暂无描述
717 次下载
4 年前更新

轩辕镜像配置手册

探索更多轩辕镜像的使用方法,找到最适合您系统的配置方式

Docker 配置

登录仓库拉取

通过 Docker 登录认证访问私有仓库

专属域名拉取

无需登录使用专属域名

K8s Containerd

Kubernetes 集群配置 Containerd

K3s

K3s 轻量级 Kubernetes 镜像加速

Dev Containers

VS Code Dev Containers 配置

Podman

Podman 容器引擎配置

Singularity/Apptainer

HPC 科学计算容器配置

其他仓库配置

ghcr、Quay、nvcr 等镜像仓库

Harbor 镜像源配置

Harbor Proxy Repository 对接专属域名

Portainer 镜像源配置

Portainer Registries 加速拉取

Nexus 镜像源配置

Nexus3 Docker Proxy 内网缓存

系统配置

Linux

在 Linux 系统配置镜像服务

Windows/Mac

在 Docker Desktop 配置镜像

MacOS OrbStack

MacOS OrbStack 容器配置

Docker Compose

Docker Compose 项目配置

NAS 设备

群晖

Synology 群晖 NAS 配置

飞牛

飞牛 fnOS 系统配置镜像

绿联

绿联 NAS 系统配置镜像

威联通

QNAP 威联通 NAS 配置

极空间

极空间 NAS 系统配置服务

网络设备

爱快路由

爱快 iKuai 路由系统配置

宝塔面板

在宝塔面板一键配置镜像

需要其他帮助?请查看我们的 常见问题Docker 镜像访问常见问题解答 或 提交工单

镜像拉取常见问题

使用与功能问题

配置了专属域名后,docker search 为什么会报错?

docker search 限制

Docker Hub 上有的镜像,为什么在轩辕镜像网站搜不到?

站内搜不到镜像

机器不能直连外网时,怎么用 docker save / load 迁镜像?

离线 save/load

docker pull 拉插件报错(plugin v1+json)怎么办?

插件要用 plugin install

WSL 里 Docker 拉镜像特别慢,怎么排查和优化?

WSL 拉取慢

轩辕镜像安全吗?如何用 digest 校验镜像没被篡改?

安全与 digest

第一次用轩辕镜像拉 Docker 镜像,要怎么登录和配置?

新手拉取配置

错误码与失败问题

docker pull 提示 manifest unknown 怎么办?

manifest unknown

docker pull 提示 no matching manifest 怎么办?

no matching manifest(架构)

镜像已拉取完成,却提示 invalid tar header 或 failed to register layer 怎么办?

invalid tar header(解压)

Docker pull 时 HTTPS / TLS 证书验证失败怎么办?

TLS 证书失败

Docker pull 时 DNS 解析超时或连不上仓库怎么办?

DNS 超时

Docker 拉取出现 410 Gone 怎么办?

410 Gone 排查

出现 402 或「流量用尽」提示怎么办?

402 与流量用尽

Docker 拉取提示 UNAUTHORIZED(401)怎么办?

401 认证失败

遇到 429 Too Many Requests(请求太频繁)怎么办?

429 限流

docker login 提示 Cannot autolaunch D-Bus,还算登录成功吗?

D-Bus 凭证提示

为什么会出现「单层超过 20GB」或 413,无法加速拉取?

413 与超大单层

账号 / 计费 / 权限

轩辕镜像免费版和专业版有什么区别?

免费版与专业版区别

轩辕镜像支持哪些 Docker 镜像仓库?

支持的镜像仓库

镜像拉取失败还会不会扣流量?

失败是否计费

麒麟 V10 / 统信 UOS 提示 KYSEC 权限不够怎么办?

KYSEC 拦截脚本

如何在轩辕镜像申请开具发票?

申请开票

怎么修改轩辕镜像的网站登录和仓库登录密码?

修改登录密码

如何注销轩辕镜像账户?要注意什么?

注销账户

配置与原理类

写了 registry-mirrors,为什么还是走官方或仍然报错?

mirrors 不生效

怎么用 docker tag 去掉镜像名里的轩辕域名前缀?

去掉域名前缀

如何拉取指定 CPU 架构的镜像(如 ARM64、AMD64)?

指定架构拉取

用轩辕镜像拉镜像时快时慢,常见原因有哪些?

拉取速度原因

查看全部问题→

用户好评

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

用户头像

oldzhang

运维工程师

Linux服务器

5

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

轩辕镜像
镜像详情
...
lucasgaitzsch/pdf-turtle
博客公告Docker 镜像公告与技术博客
热门镜像查看热门 Docker 镜像推荐
一键安装一键安装 Docker 并配置镜像源
镜像拉取问题咨询请 提交工单,官方技术交流群:1072982923。轩辕镜像所有镜像均来源于原始仓库,本站不存储、不修改、不传播任何镜像内容。
镜像拉取问题咨询请提交工单,官方技术交流群:。轩辕镜像所有镜像均来源于原始仓库,本站不存储、不修改、不传播任何镜像内容。
商务合作:点击复制邮箱
©2024-2026 源码跳动
商务合作:点击复制邮箱Copyright © 2024-2026 杭州源码跳动科技有限公司. All rights reserved.