Alfresco Community Kubernetes Deployment CLI using Helm and Docker Desktop or Kubernetes In Docker (KinD) cluster.
Additional details are available in ACS Deployment.
Requires separate install of kubectl and Helm.
Apply following configurations to Docker Desktop settings:
Settings > Resources > Advanced > Memory: 16 GB
Settings > Kubernetes > Enable Kubernetes: ON
After changing the necessary settings Apply and restart
the docker desktop.
Take a look to the KinD quickstart to learn how to install the binary cli on your machine and to learn briefly the main commands that you can run.
Apply following configurations to Docker Desktop settings:
Settings > Resources > Advanced > Memory: 16 GB
Settings > Kubernetes > Enable Kubernetes: OFF
After changing the necessary settings Apply and restart
the docker desktop.
Download the binary compiled for your architecture (Linux, Windows or Mac OS) from Releases.
You may rename the binary to
alf-k8s
, all the following samples are using this command name by default.
Using -h
flag provides detail on the use of the different commands available.
Create
Create
command produces required assets to deploy Alfresco Community in Kubernetes.
$ ./alf-k8s create -h
Create assets to deploy Alfresco in Kubernetes
Usage:
alf-k8s create [flags]
Flags:
-h, --help help for create
-k, --kubernetes string Kubernetes cluster: docker-desktop (default) or kind
-o, --output string Local Directory to write produced assets, 'output' by default
-v, --version string Version of ACS to be deployed (23.1 or 23.2)
Run the command selecting the Alfresco Community version to be deployed.
$ ./alf-k8s create -v 23.2
The previous command uses Docker Desktop as Kubernetes cluster, add
-k kind
to use kind instead.
Kubernetes assets will be produced by default in output
folder:
$ tree output
output
├── start.sh
├── stop.sh
└── values
├── community_values.yaml
├── resources_values.yaml
└── version_values.yaml
Alfresco can be deployed to Kubernetes (only in Mac OS or Linux) using provided shell script:
$ cd output
$ ./start.sh
...
You can access all components of Alfresco Content Services using the same root address, but different paths as follows:
Content: http://localhost/alfresco
Share: http://localhost/share
API-Explorer: http://localhost/api-explorer
Once the deployment has been tested, resources can be released using the following shell script:
$ ./stop.sh
release "acs" uninstalled
namespace "alfresco" deleted
release "ingress-nginx" uninstalled
namespace "ingress-nginx" deleted
The easiest way to troubleshoot issues on a Kubernetes deployment is to use the Lens desktop application, which is available for Mac, Windows and Linux. Follow the getting started guide to configure your environment.
Alternatively, the traditional Kubernetes dashboard can also be used. Presuming you have deployed the dashboard in the cluster you can use the following steps to explore your deployment:
-
Retrieve the service account token with the following command:
kubectl -n kube-system describe secret $(kubectl -n kube-system get secret | grep eks-admin | awk '{print $1}')
-
Run the kubectl proxy:
kubectl proxy &
-
Open a browser and navigate to:
http://localhost:8001/api/v1/namespaces/kubernetes-dashboard/services/https:kubernetes-dashboard:/proxy/#/login
-
Select "Token", enter the token retrieved in step 1 and press the "Sign in" button
-
Select "alfresco" from the "Namespace" drop-down menu, click the "Pods" link and click on a pod name