Giter Site home page Giter Site logo

randomnoise / plato-in-container Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 0.0 126 KB

Emulator and development containers for Plato (a document reader for Kobo e-readers)

License: MIT License

Dockerfile 100.00%
container containerization containers djvu docker e-reader epub kobo pdf plato

plato-in-container's Introduction

Plato in Container

Emulator and builder Docker containers for Plato (a document reader for Kobo e-readers)

About

The Plato Docker images are designed as development containers, designed to minimize cargo build time during the container execution time, to compile and test Plato's code as fast as possible.

Currently, Docker images are prototypes and work-in-progress; the Docker images are fat (builder: ~2GB, emulator: ~3.8GB), docker build can take a long time and the containers probably run with more than necessary options.

Motivation

Kobo devices require a specific arm-linux-gnueabihf-gcc version (Linaro GCC 4.9-2017.01) to compile the required Plato packages to be able to run Plato successfully on e-readers. (At least, I could not get Plato to work with Debian's stable repo's compiler version for the e-reader.) On the Plato emulator side; this time, emulator asks for a specific MuPDF version to be up and running.

Inspired by Jessie Frazelle's old blog post about Docker containers on the desktop, not wanting the dependency files to spread everywhere and trying to avoid dependency hell on the host machine, this repo tries to diminish the file situation with Docker containers.

Usage

Initially, get the original Plato repo:

$ cd plato-in-container
$ git submodule update --init

Builder

For building and getting the package ready for using on Kobo e-readers:

$ docker compose build plato-builder
$ docker compose run --rm plato-builder

or

$ docker compose build
$ docker compose run --rm plato-builder bash
in-container$ ./build.sh && ./dist.sh

Emulator

For running the emulator and accessing the graphics device inside the container:

$ docker compose build plato-emulator
$ docker compose run --rm plato-emulator

Emulator running inside Docker container and using local machine's display:

Home Screen Reader Screen
01-plato-emulator-home-screen 02-plato-emulator-reader-screen

Rationale

The reason Plato in Container is a separate repository and not a part of the original Plato repo is that these are not the first attempt at creating docker images for Plato. It appears the previous Dockerfiles were removed from Plato's repo because of a lack of maintenance and it seems that Plato's maintainer was not using them. On the under hand, emulator image required MuPDF libraries to be installed on the host.

I don't want to burden the maintainer with a similar PR without a track record. The separate repo also opens up an opportunity to experiment with Docker using git subtrees, git submodules and symbolic links to the locally cloned repo directories.

For reference, the previous Dockerfiles' history:

plato-in-container's People

Contributors

randomnoise avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.