pressbooks / trellis

Ansible playbooks for a WordPress LEMP stack
https://roots.io/trellis/
MIT License
0 stars 2 forks source link

Fix Kindlegen role #28

Closed SteelWagstaff closed 3 years ago

SteelWagstaff commented 3 years ago

We have a Kindlegen role in this repo (https://github.com/pressbooks/trellis/commit/4ecf923c9e3d56b1286696e6dc2c91fd5c0142a2), which fails at the 'Test for KindleGEN / Download KindleGen package' stage of the process when a user attempts to provision a Pressbooks instance.

TASK [kindlegen : KindleGEN | Test if is present] ******************************
System info:
  Ansible 2.7.12; Vagrant 2.2.14; Linux
  Trellis 1.3.0: December 7th, 2019
---------------------------------------------------
non-zero return code
fatal: [default]: FAILED! => {"changed": false, "cmd": ["test", "-x", "/usr/bin/kindlegen"], "delta": "0:00:00.005705", "end": "2020-12-01 20:12:23.766568", "rc": 1, "start": "2020-12-01 20:12:23.760863", "stderr": "", "stderr_lines": [], "stdout": "", "stdout_lines": []}
...ignoring

TASK [kindlegen : KindleGen | download package] ********************************
System info:
  Ansible 2.7.12; Vagrant 2.2.14; Linux
  Trellis 1.3.0: December 7th, 2019
---------------------------------------------------
Request failed
fatal: [default]: FAILED! => {"changed": false, "dest": "/tmp/kindlegen.tar.gz", "response": "HTTP Error 403: Forbidden", "state": "absent", "status_code": 403, "url": "http://kindlegen.s3.amazonaws.com/kindlegen_linux_2.6_i386_v2_9.tar.gz"}

Amazon has published this update to their site:

KindleGen is no longer available for download. Please use Kindle Previewer to convert, preview, and validate your eBooks. Kindle Previewer provides the same functionality of KindleGen and, in addition, provides:

  • Latest Kindle Conversion software that provides up-to-date validation for Enhanced Typesetting books (currently available for books in all languages except Simplified Chinese, Japanese, and Russian).
  • Choice of using in Graphical User Interface (GUI) for a visual inspection of your book, or, Command Line Interface (CLI) mode for bulk validation.
  • Faster preview and validation with features like thumbnails, auto-previews, and filters for pages with images, tables, drop caps, and links.
  • We recommend using EPUB format for publishing new reflowable titles and updating previously published titles. MOBI should only be used when testing on older devices that do not support Enhanced Typesetting.

https://www.amazon.com/gp/feature.html?ie=UTF8&docId=1000765211

SteelWagstaff commented 3 years ago

Can fix by taking copy of latest Kindlegen from our server and hosting in reliable place. Change URL