Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add dockerfile and a guide to build using docker #1127

Closed
wants to merge 1 commit into from

Conversation

novalagung
Copy link
Contributor

@novalagung novalagung commented Apr 16, 2020

this pr contains two things:

  • add dockerfilte
  • add a guide on how to build the project in docker

dockerizing epubcheck will make installation and execution easier, especially for anyone who doesn't have the java dependencies ready in their local computer

@novalagung novalagung changed the title add dockerfield and a guide to build using docker add dockerfile and a guide to build using docker Apr 16, 2020
@rdeltour rdeltour added priority: low To be processed when time allows status: needs review Needs to be reviewed by a team member before further processing type: maintenance The issue is related to a meta task (build system, dependency update, etc) labels Feb 24, 2021
@rdeltour
Copy link
Member

Sorry for the late reaction on this PR 😅, and thanks @novalagung for the contribution 😊.

I'm not super familiar with docker best practices (is it a common practice to push docker files in git repos?), so I'll need to spend the time to read more or get external advice before merging this.

Also, I noticed that you also pushed a Docker image for EPUBCheck on Docker Hub. This looks useful! With this image available on the hub, is it still useful to have a docker file in the repo?

Ideally we would need to setup a travis build step or GitHub action to automatically push new docker images for tagged builds…

I'm marking this PR as "needs review" for now!

@rdeltour rdeltour self-requested a review February 24, 2021 14:33
@novalagung
Copy link
Contributor Author

novalagung commented Feb 26, 2021

hi @rdeltour thank you for the response.

is it a common practice to push docker files in git repos?

Yes, it is. by including the docker file to the git repo, it'll be easier for anyone to perform build and run the epubcheck source code.

Let's try to use this epubcheck as an example. Right after cloning the repo, to be able to run the project I have to ensure JDK is installed locally, maven as well, etc. it's not a big deal for anyone who already has everything ready in their environment. but for me who rarely code java, I have to set up a lot of things first.

By putting the docker file into the project, it'll make us easier to build and run the project. meaning I don't have to set up a lot of things, so the only docker is enough. I just need to run docker build ... command and the entire build process will happen. to run the executable (in a form of a docker image), the docker run ... command is used. The full guide is added to the readme file.

Also, I noticed that you also pushed a Docker image for EPUBCheck on Docker Hub. This looks useful! With this image available on the hub, is it still useful to have a docker file in the repo?

Yes, I did push it to my docker hub. Anyone can use that docker image to run epubcheck without the need to rebuild the source code first, so simply just run docker pull ... then docker run .... at start I was using the image on my own project, then I thought it'll be useful if I pushed it to docker hub so anyone can reuse it.

However, I would say that putting the docker file into the project is still mandatory because to be able to build the image we need the docker file. especially if there is a plan to enable automatic push to the Docker hub, the build process will require the docker file ready.

Ideally we would need to setup a travis build step or GitHub action to automatically push new docker images for tagged builds…

I think so. It'll be better if epubcheck has an official docker hub image, and then the automatic update is enabled via Travis (or other CI/CD tools).

@rdeltour
Copy link
Member

Thanks for the info @novalagung, that's very useful! 👍
I'll try to have a look for the next milestone (no scheduled date yet).

@rdeltour rdeltour self-assigned this Feb 26, 2021
@rdeltour rdeltour added this to the v4.2.6 milestone Feb 26, 2021
@rdeltour rdeltour modified the milestones: v4.2.7, v5.0.0 Nov 12, 2021
@josteinaj
Copy link
Contributor

In addition, it would be great if there was a simple REST API for epubcheck. That, along with Docker, would enable us to run it as a microservice in our environment.

@rdeltour
Copy link
Member

Merged in as d0ed6a4. Thanks again @novalagung!

@rdeltour rdeltour closed this Jan 11, 2023
@novalagung novalagung deleted the build-docker branch May 23, 2023 11:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: low To be processed when time allows status: needs review Needs to be reviewed by a team member before further processing type: maintenance The issue is related to a meta task (build system, dependency update, etc)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants