i-net HelpDesk can be used from inside a Docker Container. There is a pre build container based up on an alpine release at Docker Hub. The container only brings the application and tools required to run the application.
Note: The container does not provide any default users. You have to use the Sign Up
method first. See below for advanced use cases.
Run the following command to start an i-net HelpDesk Docker Container:
docker run -d -p 8002:8002 --name helpdesk inetsoftware/i-net-helpdesk
Note: The i-net HelpDesk requires a database to run. You can use MySQL/MariaDB, Oracle or MSSQL. See below for an example using MySQL in a parallel container.
The i-net HelpDesk Docker Container should be pre-configured using either a configuration properties file or environment variables. Either way, a local installation with the specific setup should be created first. Using the Maintenance module a backup of the configuration can be created and the configuration properties file in there can be used as a basis.
Note: To have the container fully set up on startup you have to specify at least the following properties: CONF_listener__port
and CONF_licensekey
Note: In private cloud environments you have to set the property CONF_serverURL
as well. It is recommended to set this property in other environments too.
A configuration file can be added by using a volume or any other means that adds a specified configuration to the container. The default configuration file can be used or a different one can be set using an environment variable. See Environment Properties Matrix.
To create the environment variable names use the following rule:
CONF__
.
(dot) with __
(two underlines)
To make the configuration reproducible and updatable you should use a docker-compose.yml
file.
version: '2.1' services: helpdesk: image: 'inetsoftware/i-net-helpdesk:latest' restart: 'always' ports: - 8002:8002 environment: - DEFAULT_PROPFILE=/tmp/defaultConfiguration.properties - DEFAULT_CONFIG=User/Default # Set the externally visible server url ="../../../../../un-comment-and-insert-the-correct-url" #- CONF_serverURL=https://hostname.company.com:8002/ # Set the license key (un-comment and insert the full license key) #- CONF_licensekey=... # Run the application on a pre-determined port for easier mapping - CONF_listener__port=8002 # Customize an option, e.g. the theming colors - CONF_theme__themecolors={"@base-color":"#123456","@primary-color":"#428bca"} # Enable logging, route log to the container log-file - CONF_log__engine=true - CONF_log__file=/dev/stdout # Location for automatic backups - CONF_BackupLocation=/home/helpdesk/.i-net software/helpdesk_User_Default/backup
If there are more specific requirements, such as a pre-filled user database, a custom container should be created
Using the following compose example you can create a server that is started without any permission restrictions and can be used without further authentication using the public URL context.
version: '2.1' services: helpdesk: image: 'inetsoftware/i-net-helpdesk:latest' restart: 'always' ports: - 8002:8002 environment: # The User/Default configuration must be used - DEFAULT_CONFIG=User/Default # Set the license key (un-comment and insert the full license key) #- CONF_licensekey=... # Run the application on a pre-determined port for easier mapping - CONF_listener_ _port=8002 # Only guest account is active. - CONF_authentication__settings=[{"provider"\:"guest"}]
The following Dockerfile
will create a user admin
with the password password
in a new container.
FROM inetsoftware/i-net-helpdesk # Switch to root user for installation USER root # Tools RUN apk add --update linux-pam # grant pam permissions to everybody # Create User that we can log in with RUN chmod +r /etc/shadow \ && adduser -D -g "User" admin \ && echo admin:password | chpasswd \ && ln -s "/etc/pam.d/base-password" "/etc/pam.d/helpdesk" # Enable the system login. By default, the PAM plugin is disabled. ENV CONF_authentication__settings="[{'provider':'system'},{'provider':'product','userCanRegister':'true'}]" ENV CONF_plugins__activated="{}" # Switch back to product user USER helpdesk
To bundle a docker container with a MySQL database using Docker Compose, the following docker-compose.yml
script can be used as a starting point:
version: '2.1' services: helpdesk: image: 'inetsoftware/i-net-helpdesk:latest' restart: 'always' ports: - 8002:8002 links: # Connect to the prepared MySQL database - 'mysql' command: # The following wait-for.sh command allows the service to wait for an external service to become available - sh - wait-for.sh - mysql:3306 - -- # After the mysql server has started, start the actual i-net HelpDesk Server - sh - ./startServer.sh - -Dclearreports.config=User/Default - -Dsetupautoexecution=true environment: # Using the User/Default config is required in the HelpDesk - DEFAULT_CONFIG=User/Default # Set the externally visible server url ="../../../../../un-comment-and-insert-the-correct-url" #- CONF_serverURL=https://hostname.company.com:9443/ # Set the license key (un-comment and insert the full license key) #- CONF_licensekey=... # Run the application on a pre-determined port for easier mapping - CONF_listener__port=8002 # Do not force the application to overwrite a previously imported configuration # or other instances using the same MongoDB will have their configuration modified - FORCE_IMPORT_CONFIG=0 # Set up the connection the MySQL database - CONF_dbsConfigs=[{"status":"Unknown","dbName":"HDS","url":"jdbc:mysql://mysql:3306/inetHDOfficial?useSSL=false&allowPublicKeyRetrieval=true","user":"root","encodedPassword":"AU1KQVA=","host":"mysql","port":"3306","sid":"","catalog":"inetHDOfficial","driver":"mysql"}] mysql: image: 'mysql:8' restart: 'always' environment: - MYSQL_ROOT_PASSWORD=inet - MYSQL_DATABASE=inetHDOfficial - MYSQL_USER=inetHDOfficial - MYSQL_PASSWORD=inet volumes: - "/var/lib/mysql"
Note: Depending on the specific environment there may be some more options that have to be set. Please have a look at the Environment Properties Matrix.