myshellconfig/aliases_remote
2024-09-13 16:25:24 +02:00

5 lines
2.4 KiB
Text

#alias deploypvp='getatsvc; TARGETDIR=/opt/atlassian/${APP_NAME}/${APP_INST_NAME}/WEB-INF/lib; COMCSV=$(ls -t /root/INSTALL/commons-csv* |head -n1); SETTINGS=$(ls -t /root/INSTALL/at.gv.bmi.atlassian.pvp.settings* |head -n1); PVP=$(ls -t /root/INSTALL/at.gv.bmi.atlassian.pvp.authenticator.*${SVC}* |head -n1); CHARDET=$(ls -t /root/INSTALL/juniversalchardet*|head -n1); echo "Deploy $SETTINGS $PVP $COMCSV" "$CHARDET"; systemctl stop ${APP_NAME}.service ;"${TARGETDIR}"/at.gv.bmi.* "${TARGETDIR}"/"$(basename $CHARDET)" "${TARGETDIR}"/"$(basename $COMCSV)"; cp "${SETTINGS}" "${PVP}" "${COMCSV}" "${CHARDET}" "${TARGETDIR}"/.; systemctl restart ${APP_NAME} --no-block ;tailatpvp'
#alias deploypvpandstop='getatsvc; TARGETDIR=/opt/atlassian/${APP_NAME}/${APP_INST_NAME}/WEB-INF/lib; COMCSV=$(ls -t /root/INSTALL/commons-csv* |head -n1); SETTINGS=$(ls -t /root/INSTALL/at.gv.bmi.atlassian.pvp.settings* |head -n1); PVP=$(ls -t /root/INSTALL/at.gv.bmi.atlassian.pvp.authenticator.*${SVC}* |head -n1); CHARDET=$(ls -t /root/INSTALL/juniversalchardet*|head -n1); echo "Deploy $SETTINGS $PVP $COMCSV $CHARDET"; systemctl stop ${APP_NAME}.service ;rm "${TARGETDIR}"/at.gv.bmi.* "${TARGETDIR}"/"$(basename $CHARDET)" "${TARGETDIR}"/"$(basename $COMCSV)"; cp "${SETTINGS}" "${PVP}" "${COMCSV}" "${CHARDET}" ${TARGETDIR}/.'
alias deploypvp='getatsvc; TARGETDIR=/opt/atlassian/${APP_NAME}/${APP_INST_NAME}/WEB-INF/lib; COMCSV=$(ls -t /root/INSTALL/commons-csv* |head -n1); SETTINGS=$(ls -t /root/INSTALL/at.gv.bmi.atlassian.pvp.settings* |head -n1); PVP=$(ls -t /root/INSTALL/at.gv.bmi.atlassian.pvp.authenticator.*${SVC}* |head -n1); TIKA_CORE=$(ls -t /root/INSTALL/tika-core*|head -n1); TIKA_PARS=$(ls -t /root/INSTALL/tika-parsers-standard-package*|head -n1); TIKA_PARS_TEXT=$(ls -t /root/INSTALL/tika-parser-text-module*|head -n1); echo "Deploy $SETTINGS $PVP $COMCSV" "$TIKA_CORE" "$TIKA_PARS" "$TIKA_PARS"; systemctl stop ${APP_NAME}.service ;"${TARGETDIR}"/at.gv.bmi.* "${TARGETDIR}"/"$(basename $TIKA_CORE)" "${TARGETDIR}"/"$(basename $TIKA_PARS)" "${TARGETDIR}"/"$(basename $TIKA_PARS_TEXT)" "${TARGETDIR}"/"$(basename $COMCSV)"; cp "${SETTINGS}" "${PVP}" "${COMCSV}" "${TIKA_CORE}" "${TIKA_PARS}" "${TIKA_PARS_TEXT}" "${TARGETDIR}"/.; systemctl restart ${APP_NAME} --no-block ;tailatpvp'
alias getpvpversion='for base in $(find /opt/atlassian -type d -name "WEB-INF"); do echo search in "$base"; find "${base}/lib" -name "*pvp*" -exec basename {} \; ; echo "---";done'