Finding the correct global properties file to update settings

cancel
Showing results for 
Search instead for 
Did you mean: 
EddieMay
Alfresco Employee

Re: Finding the correct global properties file to update settings

Hi @arjunm1989 

If you look at @mire323 answer, you can see that if you run the docker cmds they mentioned (starting with, "execute 'docker ps' "), this will give you the location of the file.

HTH

Digital Community Manager, Alfresco Software.
Problem solved? Click Accept as Solution!
arjunm1989
Active Member

Re: Finding the correct global properties file to update settings

Yes but that is empty.

ChrisAlker
Active Member II

Re: Finding the correct global properties file to update settings

This was the same issue I found, the file was entirely empty

abhinavmishra14
Advanced

Re: Finding the correct global properties file to update settings

it will be empty and its expected by default. It would be empty unless you copy or update the global properties file during image build. All properties are set via java arguments like this, if you check your docker-compose file:

 

JAVA_OPTS: "
                -Ddb.driver=org.postgresql.Driver
                -Ddb.username=alfresco
                -Ddb.password=alfresco
                -Ddb.url=jdbc:postgresql://postgres:5432/alfresco
                -Dsolr.host=solr6
                -Dsolr.port=8983
                -Dsolr.secureComms=none
                -Dsolr.base.url=/solr
                -Dindex.subsystem.name=solr6
                -Dshare.host=127.0.0.1
                -Dshare.port=8080
                -Dalfresco.host=localhost
                -Dalfresco.port=8080
                -Daos.baseUrlOverwrite=http://localhost:8080/alfresco/aos
                -Dmessaging.broker.url=\"failover:(nio://activemq:61616)?timeout=3000&jms.useCompression=true\"
                -Ddeployment.method=DOCKER_COMPOSE
                -DlocalTransform.core-aio.url=http://transform-core-aio:8090/
                -Dalfresco-pdf-renderer.url=http://transform-core-aio:8090/
                -Djodconverter.url=http://transform-core-aio:8090/
                -Dimg.url=http://transform-core-aio:8090/
                -Dtika.url=http://transform-core-aio:8090/
                -Dtransform.misc.url=http://transform-core-aio:8090/
                -Dcsrf.filter.enabled=false
                -Xms1500m -Xmx1500m
                "

You can either put your properties as stated above, or create a global properties file and copy that to container image via DockerFile.

 

You need to update docker-compose.yml file for acs service to build from DockerFile:

alfresco:
        build:
          dockerfile: ./Dockerfile
          context: ./configs-to-override/alfresco
          args:
            ACS_TAG: ${ACS_TAG}
        mem_limit: 1500m
.....
.....

DockerFile will have following instructions:

ARG ACS_TAG

FROM alfresco/alfresco-content-repository-community:${ACS_TAG}

#Copy and override the alfresco-global.properties which comes with custom image. 
#It could be useful in cases when you already built a custom image but launch an container with some additional config in global properties.
COPY alfresco-global.properties $TOMCAT_DIR/shared/classes/alfresco-global.properties

You can find an example here for DockerFile: https://github.com/abhinavmishra14/change-acs-share-port-demo/blob/master/configs-to-override/alfres...

Service example: https://github.com/abhinavmishra14/change-acs-share-port-demo/blob/master/docker-compose.yml#L15

~Abhinav
(ACSCE, AWS SAA, Azure Admin)