Easiest Way to Install Alfresco 7.3 using Docker Compose

cancel
Showing results for 
Search instead for 
Did you mean: 

Easiest Way to Install Alfresco 7.3 using Docker Compose

angelborroy
Alfresco Employee
1 0 6,792

This blog post describes a simple method to deploy Alfresco 7.3 using Docker Compose with one single command.

 

Requirements

Docker should be installed and running. Docker Desktop installation instructions for every supported platform (Linux, macOS amd64, macOS arm64 and Windows) are available in Docker documentation.

Despite Alfresco can be deployed with less than 16 GB of RAM, using this amount of memory is recommended to get a fluid user experience. Ensure 16 GB memory is available to Docker Engine using Docker Desktop application. If you are using MacOS, the configuration is available in Preferences > Resources > Advanced section.

docker-resources-memory.png

When using Windows, WSL 2 mode is recommended. Limits on the memory can be configured using WSL 2 utility VM. Additional instructions are available in Docker Documentation.

When using Linux, Memory allocation is also available in Docker Desktop. Additional instructions are available in Docker Documentation.

 

Running Alfresco

The first step is to verify that Docker is up & ready.

$ docker -v
Docker version 20.10.21, build baeda1f

Once Docker is ready (with 16 GB of RAM available), create a new folder to hold the resources created by the Alfresco installer tool.

$ mkdir alfresco
$ cd alfresco

Type the following command in your terminal when using Linux or MacOS:

$ docker run -it -v $(pwd):/generated angelborroy/alfresco-installer

If you are using Windows, type this alternative syntax from PowerShell:

$ docker run -it -v ${PWD}:/generated angelborroy/alfresco-installer

This command will run angelborroy/alfresco-installer Docker Image in interactive mode (-it) storing the resources generated in the current folder ($(pwd)). This Docker Image is wrapping the Alfresco Docker Installer program to avoid installing dependencies in your computer.

The execution of the command will start prompting a battery of questions to customize the Alfresco installation.

DOCKER COMPOSE ALFRESCO

? Which ACS version do you want to use? (Use arrow keys)
  6.1
  6.2
  7.0
  7.1
  7.2
❯ 7.3

Details related to every questions is available in Alfresco Docker Installer project, despite you can choose default options in case of doubt.

Once all the questions have been answered, information to start Alfresco will be provided.

---------------------------------------------------
STARTING ALFRESCO

Start Alfresco using the command "docker compose up"
Once the plaform is ready, you will find a line similar to the following one in the terminal:
alfresco-1 | org.apache.catalina.startup.Catalina.start Server startup in [NNNNN] milliseconds

SERVICE URLs

   * UI: http://localhost/
   * Legacy UI (users & groups management): http://localhost/share
   * Repository (REST API): http://localhost/alfresco

Remember to use as credentials:

   * username: admin
   * password: admin

---------------------------------------------------

Additionally, a list of files and folders generated in the current folder for Alfresco configuration with Docker Compose is dumped.

   create .env
   create docker-compose.yml
   create alfresco/Dockerfile
   create alfresco/modules/amps/empty
   create alfresco/modules/jars/empty
   create share/Dockerfile
   create share/web-extension/share-config-custom-dev.xml
   create share/modules/amps/empty
   create share/modules/jars/empty
   create search/Dockerfile
   create config/nginx.conf
   create config/nginx.htpasswd
   create alfresco/modules/jars/activemq-broker-5.17.2.jar

When this Docker Compose is started, two additional folders are created:

  • data, that contains all the persistent information required by Alfresco to work
  • logs, that contains log files for different Alfresco services

If you are using Windows, the folders data and logs are not created in the directory. These resources are created as Docker Volumes and they are available in Volumes section of Docker Desktop app.

Once the Docker Compose configuration for Alfresco has been generated, use the following command to start ACS 7.3

$ docker compose up
...
alfresco-alfresco-1 | org.apache.catalina.startup.Catalina.start Server startup in [38213] milliseconds

If everything works as expected, a log line including "alfresco" and "Server startup" messages will appear in the terminal. From this point Alfresco is ready to be used. Open a browser and test the different service urls with the credentials provided by the installation program.

Alfresco UI (Alfresco Content Application)

http://localhost/

alfresco-ui.png

Alfresco Legacy UI (Alfresco Share) includes some features (like users and groups management) that are still not available in Alfresco UI

http://localhost/share

alfresco-share.png

Repository (Alfresco)

http://localhost/alfresco

alfresco-repository.png

 

 

Stopping Alfresco

Once you've finished to evaluate ACS 7.3, type Ctrl+C in your terminal or PowerShell window to stop Alfresco. All the content and configuration is persisted, so you can start Docker again from the same folder to continue the working session using the command docker compose up

 

Additional resources

 

 

About the Author
Angel Borroy is Hyland Developer Evangelist. Over the last 15 years, he has been working as a software architect on Java, BPM, document management and electronic signatures. He has been working with Alfresco during the last years to customize several implementations in large organizations and to provide add-ons to the Community based on Record Management and Electronic Signature. He writes (sometimes) on his personal blog http://angelborroy.wordpress.com. He is (proud) member of the Order of the Bee.