Installation
Table of contents
Currently, estela is a kubernetes application, but it can be extended to support different architectures 🔜.
Requirements
Docker v.20.10.x with docker-compose
Estela projects are built into docker images and added to Docker-Registry. It is also necessary to install estela resources.
It is recommended to install docker-desktop
which includes docker and docker-compose. A detailed guide on how to install it can be found here.
Kubectl >= v1.23.x
The Kubernetes command-line tool, kubectl, allows you to run commands against Kubernetes clusters.
To install kubectl
you can use following command-line code according to your OS:
-
brew install kubectl
-
sudo apt-get update sudo apt-get install -y ca-certificates curl sudo apt-get install -y apt-transport-https sudo curl -fsSLo /etc/apt/keyrings/kubernetes-archive-keyring.gpg https://packages.cloud.google.com/apt/doc/apt-key.gpg echo "deb [signed-by=/etc/apt/keyrings/kubernetes-archive-keyring.gpg] https://apt.kubernetes.io/ kubernetes-xenial main" | sudo tee /etc/apt/sources.list.d/kubernetes.list sudo apt-get update sudo apt-get install -y kubectl
A detailed installation guide can be found here
Helm >= v3.9.x
Helm is a package manager for Kubernetes.
To install Helm
you can use the following command-line code according to your OS:
-
brew install helm
-
curl https://baltocdn.com/helm/signing.asc | gpg --dearmor | sudo tee /usr/share/keyrings/helm.gpg > /dev/null sudo apt-get install apt-transport-https --yes echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/helm.gpg] https://baltocdn.com/helm/stable/debian/ all main" | sudo tee /etc/apt/sources.list.d/helm-stable-debian.list sudo apt-get update sudo apt-get install helm
Node v18.x
Node is an open-source, cross-platform JavaScript runtime environment.
To install node
you can use the following command-line code according to your OS:
-
brew install node
-
curl -fsSL https://deb.nodesource.com/setup_18.x | sudo -E bash - &&\ sudo apt-get install -y nodejs
Yarn v1.22.x
Yarn is a package manager that doubles down as project manager.
To install Yarn
you can just use npm
:
npm install --global yarn
Extra requirements
Local installation will require:
Python v3.9.x
Please refer to https://www.python.org/downloads/ and install the appropiate version of Python according to your operating system.
Minikube >= v1.25.0
Minikube is used to setup a local Kubernetes cluster.
To install minikube
you can use the following command-line code:
-
brew install minikube
-
curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64 sudo install minikube-linux-amd64 /usr/local/bin/minikube
You can use the installation/check_requirements.sh
script to verify that all requirements have been met. For example, here is an example of a successful setup:
$ bash installation/check_requirements.sh
docker version is correct: 20.10.14,
kubectl version is correct: v1.26.1
helm version is correct: v3.11.0+g472c573
yarn version is correct: 1.22.19
node version is correct: v18.0.0
python version is correct: 3.9.12
minikube version is correct: v1.28.0
Please note that command line installation is a reference and some requirements could be installed in other ways, such as using binaries.
To use the above command-line instructions on macOS you need to install homebrew.
estela runs on Linux-based and Unix-like operating systems. Still, you can use Windows Subsystem for Linux (WSL) if you are using Windows. Note: The Windows installation has not yet been tested by our team.
For the rest of the installation, open a terminal in the installation folder of the cloned estela repository.
Resources
All the named resources (except the Document Oriented Database and the SMTP Email Server) can be started locally by running this command in the installation folder:
$ make resources
If you want to start only some of the resources, modify the RESOURCES
variable of the Makefile
.
To allow the use of images stored in the local container registry, you need to add the following line to the Docker daemon config file. Then, restart Docker.
{
...
"insecure-registries" : [ "<HOST_IP>:5001" ]
...
}
Here is an example on how the config file should look:
{
"builder": {
"gc": {
"defaultKeepStorage": "20GB",
"enabled": true
}
},
"experimental": false,
"features": {
"buildkit": true
},
"insecure-registries": [
"<HOST_IP>:5001"
]
}
Where <HOST_IP> is equal to the output of:
$ minikube ssh 'grep host.minikube.internal /etc/hosts | cut -f1'
Please refer to the resources appendix for detailed information about the resources needed by Estela.
Environment Variables
First, make a copy (in the helm-chart directory) of values.yaml.example
and rename it to values.yaml
. If you do not need to define an optional variable, fill its value with an empty string ""
.
Refer to the variables appendix, and complete the helm-chart/values.yaml
file with the appropriate environment values.
The values that should be used if the resources have been deployed locally are commented in the helm-chart/values.yaml.example
file.
Helm Deployment
The images for all Estela modules must be built and uploaded to the Docker Container Registry prior to installing the Helm application.
If you are using a local registry, you can build and upload the images by running the following:
$ make images
The Helm deployment requires a release name and a namespace to identify the current version of the installed application. By default, the values of these variables are base
and default
, respectively.
To proceed with the installation, perform the following steps:
-
Install the Helm application by running:
$ make install
-
If you are using Minikube, you will need an external IP for the API Django service. To obtain this, please run the following command in a new terminal:
$ minikube tunnel
-
Now, we will need to apply necessary settings for Estela to function properly. This includes updating the application with the value of the Django service external IP, performing migrations, and creating the needed Django superusers. This can be done by running:
$ make setup
- If you are using the local resources, specifically MinIO, you will need to create a public bucket with the name specified in the BUCKET_NAME_PROJECTS variable.
- Go to the web dashboard and log in using the default credentials:
minioadmin : minioadmin
. - Then, create a bucket using the BUCKET_NAME_PROJECTS value as the bucket name.
- Finally, go to the bucket’s page, click the Manage button of the newly created bucket, and change the Access Policy to public.
- Go to the web dashboard and log in using the default credentials:
-
You can create a new superuser to manage and use estela by running:
$ make createsuperuser
The estela application is now ready to use!
Web Deployment
To build the estela web application, run:
$ make build-web
Then, execute the web application locally by running:
$ make run-web
Visit the web application and start creating projects!
You can use the superuser credentials that you set with make createsuperuser
to login to the web application.
Uninstalling estela
To uninstall estela, simply run:
$ make uninstall
Final Notes
If you have installed estela locally, you do not need to repeat all the steps every time you reboot your computer. Once the installation is complete, you can start the application and resources with:
$ make start
$ minikube tunnel # Run this in another terminal
And stop the application along with all the resources with:
$ make stop