Files
acs-community-packaging/dev/aliases

54 lines
3.2 KiB
Plaintext
Executable File

# The aliases in this script provide simple commands to build projects, start tomcat and combinations of these. This
# give the flexibility to only rebuild or repackage parts of the codebase that have changed.
#
# Once the repository component has been built, it will need to be combined with other ACS components in the
# acs_community_packaging projects.
#
# When developing code, you will normally not be creating repository docker images, but will be creating war files and
# then running them in a local tomcat instance. To provide the environment needed to do this you will need to start a
# docker-compose environment to provide access to a databases and other ACS components.
#
# Aliases to build a sequence of projects and start tomcat - remember to start a CLEAN docker-compose environment - see envUp
# com - builds alfresco-community-repo & acs-community-packaging
#
# Aliases to build projects WITHOUT creating docker images
# comR - alfresco-community-repo
# comP - acs-community-packaging
#
# Aliases to build projects including DOCKER images
# comRD - alfresco-community-repo
# comPD - acs-community-packaging
# Aliases to start tomcat in a CLEAN environment - remember to start a docker-compose environment - see envUp
# comT - acs-community-packaging
# comTDebug - acs-community-packaging (uses mvnDebug to allow a debugger to be attached)
# Aliases to start tomcat REUSING an existing environment (database and alf_data directory)
# comO - acs-community-packaging
# comODebug - acs-community-packaging (uses mvnDebug to allow a debugger to be attached)
export TAG=latest
alias comR='(cd alfresco-community-repo && mvn clean install -DskipTests=true -Dversion.edition=Community)'
alias comP='(cd acs-community-packaging && mvn clean install -Dmaven.javadoc.skip=true)'
alias comRD="(cd alfresco-community-repo && mvn clean install -PcommunityDocker -Dimage.tag=$TAG -DskipTests=true -Dversion.edition=Community)"
alias comPD="(cd acs-community-packaging && mvn clean install -PcommunityDocker -Dimage.tag=$TAG -Drepo.image.tag=$TAG -Dmaven.javadoc.skip=true)"
alias comT=' (cd acs-community-packaging && mvn clean install -Prun,withShare)'
alias comTDebug='(cd acs-community-packaging && mvnDebug clean install -Prun,withShare)'
alias comO=' (cd acs-community-packaging && mvn install -Prun,withShare -rf dev/dev-acs-amps-overlay)'
alias comODebug='(cd acs-community-packaging && mvnDebug install -Prun,withShare -rf dev/dev-acs-amps-overlay)'
alias com='comR && comP && comT'
alias comD='comRD && comPD'
# Clean up of docker images and content stores (alf_data directories)
alias drm='docker rm -f $(docker ps -q)'
alias arm='rm -rf `find . -name alf_data`'
alias envUp='docker-compose -f acs-community-packaging/dev/docker-compose.yml up'
alias envStop='docker-compose -f acs-community-packaging/dev/docker-compose.yml stop'
alias envKill='docker-compose -f acs-community-packaging/dev/docker-compose.yml kill'
alias envRm='docker-compose -f acs-community-packaging/dev/docker-compose.yml rm'