Stacks/Gotenberg/Migrate from AthenaPDF

Migrate from AthenaPDF to Gotenberg

Replace the AthenaPDF service, application client, and stored CMS configuration with Gotenberg 8 while keeping the conversion API private inside your Wodby app.

Compatibility

AthenaPDF and Gotenberg are not API-compatible

This is not a drop-in replacement.

AthenaPDF accepts conversion requests through /convert with an authentication key. Gotenberg 8 accepts multipart/form-data POST requests and returns the generated file. Changing only the service hostname or port leaves AthenaPDF clients and stored CMS configuration incompatible.

Drupal 10.3 and 11

Use the contributed Gotenberg module. It wraps the Gotenberg PHP client and includes an Entity Print backend. It does not convert configuration or custom code from the older Athena PDF API module.

composer require 'drupal/gotenberg:^1.0'

WordPress

Wodby does not provide a WordPress-specific Gotenberg plugin. Use a custom plugin or an existing PDF plugin only when it explicitly supports a remote Gotenberg 8 API. Composer-managed projects can use the official PHP client directly.

composer require gotenberg/gotenberg-php:^2

Custom PHP

Use the official Gotenberg PHP client or send multipart requests with your existing HTTP client. The Gotenberg 8 client is version 2.x.

Private endpoint

Configure the application

Wodby 1 migration sets GOTENBERG_ENDPOINT on the target PHP service to the private in-cluster URL, normally http://gotenberg:3000. WordPress and custom PHP code must read this variable explicitly.

The Drupal module stores its base URL in Drupal configuration; it does not read the environment variable automatically. Add this override to your environment-specific settings.php:

$config['gotenberg.settings']['base_url'] =
  getenv('GOTENBERG_ENDPOINT') ?: 'http://gotenberg:3000';

Application migration

Migration checklist

  1. Find every AthenaPDF dependency: ATHENAPDF_URL, ATHENAPDF_PASSWORD, stored athenapdf_api configuration, custom clients, and calls to /convert.
  2. Install a Gotenberg-aware module or client and configure it to use GOTENBERG_ENDPOINT.
  3. Replace AthenaPDF GET requests with the corresponding Gotenberg multipart POST route. Use /forms/chromium/convert/url for a URL or /forms/chromium/convert/html with a required index.html upload for rendered HTML.
  4. Map paper size, margins, media type, backgrounds, headers, footers, cookies, timeouts, and JavaScript wait behavior explicitly. AthenaPDF options are not translated automatically.
  5. After importing a Wodby 1 database, replace stored AthenaPDF URL and authentication configuration through a config import, deployment hook, or CMS administration page.
  6. Compare representative PDFs before switching traffic: fonts, images, authenticated assets, page breaks, headers, backgrounds, file size, and failure behavior.

Keep Gotenberg private after testing

If only services inside the app call Gotenberg, disable its technical route under App instance → Endpoints → Routes after validation. The private http://gotenberg:3000 endpoint continues to work, while the conversion API is no longer exposed publicly.

Learn about endpoints and routes