2018-03-07 23:38:02 +00:00
|
|
|
# NAME ibm/spectrumprotect
|
2019-12-13 04:03:43 +00:00
|
|
|
# VERSION 8.1.9
|
2018-03-07 23:38:02 +00:00
|
|
|
# BUILD docker build -t="ibm/spectrumprotect:latest" .
|
|
|
|
# START docker run -dp 1500:1500 [ -p 1543:1543 ] -v source:/tsm -v source:/data --restart=always --name=spectrum-protect ibm/spectrumprotect
|
|
|
|
|
|
|
|
# Since SP is supported on RHEL and its not available in docker, we'll use CentOS.
|
|
|
|
FROM centos:7
|
|
|
|
|
|
|
|
# OS Installation Prerequisites
|
|
|
|
RUN yum -y install http://yum.leenooks.net/CentOS/7/base/redhat-release-7-6.el7.centos.12.2.x86_64.rpm libaio ksh compat-libstdc++-33 numactl && yum clean all && rm -rf /var/tmp/*
|
|
|
|
|
|
|
|
# Installation
|
|
|
|
COPY install.xml install-fp.xml /tmp/
|
|
|
|
|
2020-04-23 02:14:29 +00:00
|
|
|
# New Install - Base level without License
|
|
|
|
## If you have the version from PPA (with license files), then use install.xml instead of install-fp.xml
|
2019-12-13 04:03:43 +00:00
|
|
|
RUN SOURCE_URL=http://YOUR_SITE_URL_HERE SOURCE=8.1.9.000-IBM-SPSRV-Linuxx86_64.bin && \
|
2019-05-06 04:23:48 +00:00
|
|
|
mkdir -p /tmp/build && cd /tmp/build && \
|
2019-12-13 04:03:43 +00:00
|
|
|
curl -SL ${SOURCE_URL}/${SOURCE} > tsm && chmod +x tsm && ./tsm && rm -f tsm && \
|
2018-03-11 00:24:07 +00:00
|
|
|
./install.sh -s -input /tmp/install-fp.xml -acceptLicense && \
|
|
|
|
rm -rf /tmp/build /tmp/install*xml
|
2018-03-07 23:38:02 +00:00
|
|
|
|
2019-05-06 04:23:48 +00:00
|
|
|
## New Upgrade Install - Need to get license from base level - which you get from PPA. the patch you can get from Fixcentral
|
|
|
|
## https://www.ibm.com/support/fixcentral
|
|
|
|
## http://public.dhe.ibm.com/storage/tivoli-storage-management/maintenance/server/v8r1/Linux/8.1.?.???/x86_64/ ... for maintenance releases (without license files).
|
2019-12-13 04:03:43 +00:00
|
|
|
#RUN SOURCE_URL=http://YOUR_SITE_URL_HERE SOURCE=SP_8.1_LIN86_SER_STG_ML.bin FIXPACK=8.1.9.000-IBM-SPSRV-Linuxx86_64.bin && \
|
2019-05-06 04:23:48 +00:00
|
|
|
# mkdir -p /tmp/build/base && cd /tmp/build/base && \
|
2019-12-13 04:03:43 +00:00
|
|
|
# curl -SL ${SOURCE_URL}/${SOURCE} > tsm && chmod +x tsm && ./tsm && rm -f tsm && \
|
2019-05-06 04:23:48 +00:00
|
|
|
# ./install.sh -s -input /tmp/install.xml -acceptLicense && \
|
|
|
|
# rm -rf /tmp/build/base && \
|
|
|
|
# mkdir -p /tmp/build/patch && cd /tmp/build/patch && \
|
2019-12-13 04:03:43 +00:00
|
|
|
# curl -SL ${SOURCE_URL}/${FIXPACK} > tsm && chmod +x tsm && ./tsm && rm -f tsm && \
|
2019-05-06 04:23:48 +00:00
|
|
|
# ./install.sh -s -input /tmp/install-fp.xml -acceptLicense && \
|
|
|
|
# rm -rf /tmp/build /tmp/install*xml
|
|
|
|
|
2018-03-07 23:38:02 +00:00
|
|
|
# Dont forget to change the user in the init file too
|
|
|
|
ENV USER=tsm USERDIR=/tsm USERID=201 GROUPID=201
|
|
|
|
|
|
|
|
# Setup User
|
|
|
|
RUN groupadd servers -g ${GROUPID} && useradd -d ${USERDIR} -u ${USERID} -g ${GROUPID} -s /bin/bash ${USER}
|
|
|
|
|
|
|
|
# Server options file in place
|
|
|
|
COPY dsmserv.opt tsmdbmgr.opt ${USERDIR}/
|
|
|
|
COPY dsm.sys /opt/tivoli/tsm/server/bin/dbbkapi/
|
|
|
|
RUN chmod a+r /opt/tivoli/tsm/server/bin/dbbkapi/dsm.sys
|
|
|
|
|
|
|
|
# Create TSM Instance
|
|
|
|
# Change the default directory for the database to be the same as the instance directory for the server.
|
|
|
|
RUN /opt/tivoli/tsm/db2/instance/db2icrt -a server -s ese -u ${USER} ${USER} && \
|
|
|
|
mkdir -m 750 /database && chown ${USER}:servers /database /tsm/dsmserv.opt /tsm/tsmdbmgr.opt && \
|
|
|
|
su ${USER} -lc "db2 update dbm cfg using dftdbpath ${USERDIR} && db2set -i ${USER} DB2NOEXITLIST=ON"
|
|
|
|
|
|
|
|
# Setup sqllib/userprofile
|
|
|
|
RUN su ${USER} -lc "echo setenv LD_LIBRARY_PATH /opt/tivoli/tsm/server/bin/dbbkapi:/usr/local/ibm/gsk8_64/lib64:\\\$LD_LIBRARY_PATH >> sqllib/usercshrc && echo export LD_LIBRARY_PATH=/opt/tivoli/tsm/server/bin/dbbkapi:/usr/local/ibm/gsk8_64/lib64:\\\$LD_LIBRARY_PATH >> sqllib/userprofile && echo export DSMI_CONFIG=${USERDIR}/tsmdbmgr.opt >> sqllib/userprofile && echo export DSMI_DIR=/opt/tivoli/tsm/server/bin/dbbkapi >> sqllib/userprofile && echo export DSMI_LOG=${USERDIR} >> sqllib/userprofile"
|
|
|
|
|
|
|
|
# An admin macro to create the admin user
|
|
|
|
COPY admin.macro /tsm/
|
|
|
|
# init is how we start our container, it supports a "setup" mode for new installs
|
|
|
|
COPY init /sbin/
|
|
|
|
|
|
|
|
# Our final docker parameters
|
|
|
|
EXPOSE 1500 1543
|
|
|
|
VOLUME [ "${USERDIR}","/database","/data" ]
|
|
|
|
ENTRYPOINT [ "/sbin/init" ]
|
|
|
|
CMD [ "start" ]
|
2018-03-21 05:29:47 +00:00
|
|
|
|
|
|
|
# Set out local time
|
|
|
|
RUN ln -sf /usr/share/zoneinfo/Australia/Melbourne /etc/localtime
|