Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • giles.base.url: the final URL Giles will run at (e.g. http://myserver.org/giles). Giles will use that URL to build links to Digilib content.

  • admin.password: the password for you admin user. It should be encoded with BCrypt strength=4. Default is "admin".

  • admin.username (optional): if you want your admin user to have a different name than "admin", you can specify that with this property.

  • github.clientId: OAuth client id of your GitHub application registration.

  • github.secret: OAuth client secreate of your GitHub application registration.

  • db_files: Path to a folder in your file system that will hold Giles' database files.

  • db.driver: if you don't use MySQL you can specify the appropriate driver here. Note that if you are not using MySQL you will also have to add the correct driver dependency to the pom.xml.

  • db.database.url: the url to the database (most likely something like jdbc:mysql://localhost:3306/giles).

  • db.user: username of your database user.

  • db.password: password of your database user.

  • digilib.url: url to your Digilib installation. The path should be the path to the Scaler servlet (e.g. http://myserver.org/digilib/servlet/Scaler)

  • digilibBaseDir: path to the digilib directory that should hold your images. Digilib has to have access to this directory.

  • jars.url: url to your Jars installation.

  • buildNumber (optional): if you want Giles to show a specific version number, you can specify that version number with this property.

  • pdfBaseDir: path to a folder in the file system to store uploaded PDFs
  • pdf.conversion.dpi (optional): dpi used for converting PDFs to images. Default is 600.
  • pdf.conversion.type (optional): image type to use when converting PDFs to images. Options are:

    • RGB (Red, Green, Blue) [default] 

    • ARGB (Alpha, Red, Green, Blue)

    • GRAY (Shades of gray)

    • BINARY (Black or white)

  • pdf.conversion.format (optional): image format to use when converting PDFs to images. Default is tiff.

    • Should be one of the following: 
      JPG, jpg, tiff, bmp, BMP, pcx, PCX, gif, GIF, WBMP, png, PNG, raw, RAW, JPEG, pnm, PNM, tif, TIF, TIFF, wbmp, jpeg

Step-by-step guide

You will probably not getting around learning a little bit about Maven in order to build Giles, but this step-by-step guide hopefully makes it as easy as possible. 

  1. Install Maven
  2. In a terminal go into the folder giles-{version}/giles-spring
  3. You need only one command to build Giles: mvn clean package. This will delete all previous built files and generate a war file. However, you need to specify the above listed properties for Giles to work correctly.
  4. To specify a property when running Maven, the easiest way is to append -D{property_name}={property_value}. For example, if your database user is called "giles", then you would append -Ddb.user=giles to the Maven command. The complete command would look like this: mvn clean package -Ddb.user=giles.
  5. Append each property to the command like described in step 4. You complete command string will look something like this:

    mvn clean package -Ddb_files=/path/to/db/files -Dadmin.password=GilesPassword -Dgithub.clientId=githubClientId -Dgithub.secret=githubClientSecret -Ddb.driver=com.mysql.jdbc.Driver -Ddb.database.url=jdbc:mysql://localhost:3306/giles -Ddb.user=giles -Ddb.password=GilesDbPassword -Ddigilib.url=http://myserver.org/digilib/servlet/Scaler -DdigilibBaseDir=/path/to/digilib/images -Djars.url=http://myserver.org/jars -Dgiles.base.url=http://myserver.org/giles -DpdfBaseDir=/path/to/pdfs/folder

     

  6. Maven will create a new folder in giles-spring called target. If Maven ran successfully you will find a file called giles.war inside this folder.

  7. Simply put giles.war into your Tomcat's webapp directory and you should be good to go!

...