Skip to content
Open
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
4 changes: 2 additions & 2 deletions helix-p4d/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -62,5 +62,5 @@ HEALTHCHECK --interval=1m --timeout=5s --start-period=30s \

SHELL ["/bin/bash", "-c"]
ENTRYPOINT ["/docker-entrypoint.sh"]
# Using shell-form is required for ${P4PORT} to be correctly resolved (not working in JSON format).
CMD gosu perforce p4d -p "${P4PORT}"
# Using shell-form is required for ${P4PORT} and ${P4D_CASE_SENSITIVE_FLAG} to be resolved at runtime.
CMD gosu perforce p4d "${P4D_CASE_SENSITIVE_FLAG}" -p "${P4PORT}"
6 changes: 6 additions & 0 deletions helix-p4d/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,12 @@ if [[ "${P4D_USE_UNICODE}" == "true" ]]; then
export P4CHARSET="${P4CHARSET:-auto}"
fi

if [[ "${P4D_CASE_SENSITIVE}" == "true" ]]; then
export P4D_CASE_SENSITIVE_FLAG=-C0
else
export P4D_CASE_SENSITIVE_FLAG=-C1
fi

# validate swarm trigger parameters
if [[ "${INSTALL_SWARM_TRIGGER}" == "true" ]]; then
if [[ -z "${SWARM_TRIGGER_HOST}" ]]; then
Expand Down
8 changes: 4 additions & 4 deletions helix-p4d/docker-startup.d/11-configure-tls-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ set -e

# install TLS certificate files
if [[ -n "${P4D_SSL_TLS_VERSION_MIN}" ]]; then
echo "Running: set ssl.tls.version.min=${P4D_SSL_TLS_VERSION_MIN}"
gosu perforce p4d -r "${P4ROOT}" -c "set ssl.tls.version.min=${P4D_SSL_TLS_VERSION_MIN}"
echo "Running: p4d ${P4D_CASE_SENSITIVE_FLAG} -r ${P4ROOT} -c set ssl.tls.version.min=${P4D_SSL_TLS_VERSION_MIN}"
gosu perforce p4d "${P4D_CASE_SENSITIVE_FLAG}" -r "${P4ROOT}" -c "set ssl.tls.version.min=${P4D_SSL_TLS_VERSION_MIN}"
fi
if [[ -n "${P4D_SSL_TLS_VERSION_MAX}" ]]; then
echo "Running: set ssl.tls.version.max=${P4D_SSL_TLS_VERSION_MAX}"
gosu perforce p4d -r "${P4ROOT}" -c "set ssl.tls.version.max=${P4D_SSL_TLS_VERSION_MAX}"
echo "Running: p4d ${P4D_CASE_SENSITIVE_FLAG} -r ${P4ROOT} -c set ssl.tls.version.max=${P4D_SSL_TLS_VERSION_MAX}"
gosu perforce p4d "${P4D_CASE_SENSITIVE_FLAG}" -r "${P4ROOT}" -c "set ssl.tls.version.max=${P4D_SSL_TLS_VERSION_MAX}"
fi
2 changes: 1 addition & 1 deletion helix-p4d/docker-startup.d/40-enable-unicode.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ set -e
# make sure that p4d is switched to unicode mode
if [[ "${P4D_USE_UNICODE}" == "true" ]]; then
if gosu perforce p4dctl list 2>/dev/null | grep -q "${P4NAME}"; then
gosu perforce p4d -xi -r "${P4ROOT}"
gosu perforce p4d "${P4D_CASE_SENSITIVE_FLAG}" -xi -r "${P4ROOT}"
fi
fi