Shared volumes
By definition, containers are isolated from the host machine, but you can access your local file system through the Docker concept of shared volumes. You can use three different types of shared volumes with the DockMaker
command.
Override Files volume
When you use the DockMaker
command, an override volume is generated. This volume contains all the changes that must be made to the basic artifact files to create the configuration desired. The volume binds the generatedFiles/fileOverride
directory on the host with the /docker-entrypoint-init
directory on the container. When you start the container, the files present in this directory overwrites the files and directories in the /opt/pentaho/data-integration
or /opt/pentaho/pentaho-server
directory, depending on which one is in use.
If you need any additional files, drivers, or other items placed in the application’s directory, just add them with the proper path to the fileOverride
directory.
Note: Any changes you make in this volume will be lost if the command tool is executed again, which is why the command line has the option prepare the container without building it. In many cases, you may need to make more changes to the templates generated by the DockMaker
command. If you want to back up the files generated or manually change them, rename the generatedFiles
directory or copy the directory to another location. If you take this action, you may need adjust some paths associate with parameters to the DockMaker
command.
Metastore volume
Create an arbitrary directory on your host file system to serve as the shared folder.
For example, you can use
d:\metastore
on Windows.Copy the
.kettle
and.pentaho
directories from your home directory to shared folder, thed:/metastore
directory for this example.Copy any other files you need for processing your use case.
In our example, the
d:/metastore
directory will then be bound to the/home/pentaho
directory for the container.Use the
DockMaker
command with-M
parameter specified.For example,
-M d:/metastore
.
Because linking directly to your own metastore may break the container contract, you can copy your metastore and bind to that copy. Perform the following steps to bind to a copy of your metastore:
Bind to a copy of your metastore
You generate this volume by specifying the -M
or –metastore
parameter when using the DockMaker
command. Specifying the parameter helps to create a bi-directional bind on a metastore
directory. It binds the directory defined by the parameter with the /home/pentaho
directory on the container.
Database volume
The database volume is only created when you start a Pentaho Server container. This volume contains all the database tables associated with the server repository, quartz scheduler, and log tables. When the database container is started for the first time, the container runs the DDL provided in generatedFiles
, which then defines and populates the tables needed.
Last updated
Was this helpful?