iksnae / actual-intelligence

A practical, non-technical guide to using AI tools like ChatGPT in everyday life
MIT License
0 stars 0 forks source link

Use the iksnae/book-builder Docker image in GitHub workflow #36

Closed khaos-codi closed 3 months ago

khaos-codi commented 3 months ago

This PR updates the GitHub workflow to use the newly created iksnae/book-builder Docker image instead of manually installing dependencies.

Changes

  1. Updated GitHub Workflow:

    • Modified .github/workflows/build-book.yml to use the iksnae/book-builder:latest container
    • Removed unnecessary steps for installing Node.js and other dependencies
    • Added conditional npm install that only runs if a package.json file exists
  2. Updated README.md:

    • Added information about the Docker image
    • Included instructions for local building using Docker
    • Kept the manual installation instructions as an alternative

Benefits

Testing

This change has been tested by verifying that the Docker image includes all necessary dependencies, including Node.js 20.x, npm, Pandoc, LaTeX, and Calibre.

After merging, please monitor the next workflow run to ensure everything works as expected.

khaos-codi commented 3 months ago

Update: GitHub Pages Deployment Issue

During testing, I discovered that the GitHub Pages deployment step fails when using the Docker container due to a missing rsync package. I've created an issue to add rsync to the Dockerfile.

Temporary Workaround

Until the Docker image is updated, you can add the following step to your workflow before the GitHub Pages deployment step:

- name: Install rsync for GitHub Pages deployment
  run: |
    apt-get update && apt-get install -y rsync

This will ensure that the GitHub Pages deployment action has the necessary tools to deploy your site. Once the Docker image is updated with rsync, this step can be removed.