Skip to content

JeffersonLab/resize

Repository files navigation

resize CI Docker

A Java EE 8 web application for resizing images via a wrapper to ImageMagick, developed for use by Presenter.

Screenshot



Quick Start with Compose

  1. Grab project
git clone https://github.com/JeffersonLab/resize
cd resize
  1. Launch Compose
docker compose up
  1. Navigate to page
http://localhost:8080/resize

Install

This application requires a Java 11+ JVM and standard library to run, plus a Java EE 8+ application server (developed with Wildfly).

  1. Install ImageMagick
  2. Download Wildfly 26.1.3
  3. Configure Wildfly and start it
  4. Download resize.war and deploy it to Wildfly
  5. Navigate your web browser to localhost:8080/resize

Configure

Runtime

Set the path to ImageMagick mogrify executable via MOGRIFY environment variable.

Build

This project is built with Java 17 (compiled to Java 11 bytecode), and uses the Gradle 7 build tool to automatically download dependencies and build the project from source:

git clone https://github.com/JeffersonLab/resize
cd resize
gradlew build

Note: If you do not already have Gradle installed, it will be installed automatically by the wrapper script included in the source

Note for JLab On-Site Users: Jefferson Lab has an intercepting proxy

Release

  1. Bump the release date and version number in build.gradle and commit and push to GitHub (using Semantic Versioning).
  2. Create a new release on the GitHub Releases page corresponding to the same version in the build.gradle. The release should enumerate changes and link issues. A war artifact can be attached to the release to facilitate easy install by users.
  3. Build and publish a new Docker image from the GitHub tag. GitHub is configured to do this automatically on git push of semver tag (typically part of GitHub release) or the Publish to DockerHub action can be manually triggered after selecting a tag.
  4. Bump and commit quick start image version

Deploy

At JLab this app is found internally at wildfly6.acc.jlab.org/resize and at wildflytest6.acc.jlab.org/resize. The ace.jlab.org and acctest.acc.jlab.org proxy servers do not proxy this internal only service. A deploy script is provided to automate wget and deploy. Example:

/root/setup/deploy.sh resize v1.2.3

JLab Internal Docs: InstallGuideWildflyRHEL9