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

Base fork commits #83

Draft
wants to merge 19 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
72 changes: 70 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,70 @@
# TIBCO JasperReports® Server for Containers
This project intends to build, configure, and deploy TIBCO JasperReports® Server and Scalable Query Engine on Docker and Kubernetes.
# TIBCO JasperReports® Server for minikube
This repository is a fork of the [TIBCOSoftware/js-docker](https://github.com/TIBCOSoftware/js-docker) repository.

This project intends to build and deploy a minimal TIBCO JasperReports® Server Professional Edition installation to a local Kubernetes cluster using [minikube](https://github.com/kubernetes/minikube).

<img src="./jrs-cluster.png" alt="JasperReports Server minikube cluster">

This project contains a bash script that aims to codify the steps found in the base repo docs here:
- [Use Case: Deploying TIBCO JasperReports® Server Using PostgreSQL Container in K8s Cluster](./jaspersoft-containers/K8s/jrs/README.md#use-case-deploying-tibco-jasperreports-server-using-postgresql-container-in-k8s-cluster)

<br>

# Prerequisites

1. [Docker-engine (19.x+)](https://docs.docker.com/engine/install/)
1. [minikube](https://minikube.sigs.k8s.io/docs/start/)
1. [Docker Compose (3.9+)](https://docs.docker.com/compose/install/)
1. [Helm 3.5](https://helm.sh/docs/intro/)
1. [kubectl commandline tool](https://kubernetes.io/docs/tasks/tools/)
1. TIBCO JasperReports&reg; Server
1. Minimal Knowledge of Docker and K8s

# Setup
Clone the project
```
git clone [email protected]:pdeters/js-docker-mk.git
cd js-docker-mk
```
Download a commercial edition of TIBCO JasperReports® Server WAR File installer zip into the current directory.
- _Currently this works for exactly_ `TIB_js-jrs_8.1.0_bin.zip`


Obtain a JRS license file and place it in the current directory as `jasperserver.license`

# Run
**Run the default setup script:**
```
sh minikube/setup.sh
```

This script will delete and recreate minikube, create and customize necessary files in the base repository and unzipped installer directories, then build and deploy the Docker images to minikube using Docker Compose and Helm.

<br>

**Run the default setup script, accepting all prompts:**

The default setup script will prompt you before doing anything destructive (such as running `minikube delete`), but you can skip these prompots using the `-f` flag:
```
sh minikube/setup.sh -f
```

<br>

**Run the setup script, with a custom k8s namespace:**

By default this script will install all k8s resources in the `jasper-reports` namespace, but you may also provide your own using the `-n` flag:
```
sh minikube/setup.sh -n custom-namespace
```

<br>

**Run the cleanup script:**

By design this script aims to not modify any of the asset files in the base repository, so once the script has completed you should expect to see several modified and untracked files (aside from the zip and license files you initially [setup](#Setup)).

It's not reccomened to commit these changes, so after the setup script completes, you can run it again to cleanup using the `-c` flag:
```
sh minikube/setup.sh -c
```
Binary file added jrs-cluster.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions minikube/conf/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
jasperserver.license
33 changes: 33 additions & 0 deletions minikube/conf/docker.default_master.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
################################################################################
# This is a custom version of:
# ../jasper-containers/Docker/jrs/resources/default-properties/
# default_master.properties
################################################################################

# application server
appServerType = tomcat
appServerDir = /usr/local/tomcat

# database host
dbType=postgresql
# Docker Compose
#dbHost=repository
# For docker for desktop windows and mac
# host.docker.internal
## for k8s
## repository-postgresql.default.svc.cluster.local

# CUSTOM: THe '.K8S_NAMESPACE.' segment will be replaced with the correct namespace
dbHost=repository-postgresql.K8S_NAMESPACE.svc.cluster.local
js.dbName=jasperserver
dbUsername=postgres
dbPassword=postgres

#############SCALABLE QUERY ENGINE PROPERTIES###########
scalableQueryEngine.enabled=false
scalableQueryEngine.url=http://localhost:8081

chrome.path=/usr/bin/chromium

# misc
preserve_master_properties_footer_comments_when_encrypting_buildomatic=true
28 changes: 28 additions & 0 deletions minikube/conf/docker.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
################################################################################
# This is a custom version of:
# ../jasper-containers/Docker/jrs/.env
################################################################################

INSTALL_CHROMIUM=false
JASPERREPORTS_SERVER_APP_IMAGE_NAME=jasperserver-webapp
JASPERREPORTS_SERVER_BUILDOMATIC_IMAGE_NAME=jasperserver-buildomatic
JASPERREPORTS_SERVER_VERSION=8.1.0
JASPERREPORTS_SERVER_APP_IMAGE_TAG=8.1.0
JASPERREPORTS_SERVER_BUILDOMATIC_IMAGE_TAG=8.1.0
TOMCAT_BASE_IMAGE=tomcat:9.0.54-jdk11-openjdk
JDK_BASE_IMAGE=openjdk:11-jdk
RELEASE_DATE=May 13,2022

# JS_INSTALL_TARGETS=gen-config pre-install-test-pro prepare-all-pro-dbs-normal

# CUSTOM: Used the "for minimal setup" suggested targets
JS_INSTALL_TARGETS=set-minimal-mode gen-config pre-install-test-pro prepare-js-pro-db-minimal

## For including samples gen-config pre-install-test-pro prepare-all-pro-dbs-normal
## For minimal setup set-minimal-mode gen-config pre-install-test-pro prepare-js-pro-db-minimal

# To connect the Scalable Adhoc worker
# docker for desktop , it should be host.docker.internal
# for linux , use the complete DNS or host IP
SCALABLE_QUERY_ENGINE_ENABLED=false
SCALABLE_QUERY_ENGINE_URL=http://host.docker.internal:8081
Loading