Installation Process
To initially install your Generator instance, you fill follow these steps. Rustici’s Delight team will work with you closely during this process, so we’ll be available to walk you through this and answer any questions you have.
Obtain Credentials:
- Rustici will securely provide credentials to access the ECR repository containing the Generator release images.
Download the Image:
- Use the provided credentials to pull the Docker images.
- Example
bash
commands:
export AWS_ACCESS_KEY_ID=[your access key id] export AWS_SECRET_ACCESS_KEY=[your access secret key] # Log into release ECR repo aws ecr get-login-password --region us-east-1 | docker login --username AWS --password-stdin 025066246552.dkr.ecr.us-east-1.amazonaws.com # Download the release docker pull 025066246552.dkr.ecr.us-east-1.amazonaws.com/rustici-generator:[generator version]
Create Database and RabbitMQ Broker:
- Install and start your PostgreSQL database and RabbitMQ broker. Refer to their respective documentation for details.
- In our hosted environments, we rely on AWS RDS and AWS MQ to host these. We’ve also had success in developer environments using the vendor-provided Docker images.
Set Up Environment Variables:
- A comprehensive list of configurable variables, including descriptions and recommended values, is available on this page.
- You can pass these environment variables into the app containers using the method that best suits your team’s workflow. Common approaches include:
- Recording them in a
.env
file. - Passing them directly with the
-e
flag in thedocker run
command. - Defining them in the task definition when using AWS ECS.
- Other container orchestration methods as applicable.
- Recording them in a
Start the Containers:
- Start the required containers:
- At least one container for the API.
- At least one container for the worker.
- Note: The worker container requires the
IS_WORKER
environment variable to be set totrue
. - Example command:
docker run --name rustici-generator-backend --env-file .env -d 025066246552.dkr.ecr.us-east-1.amazonaws.com/rustici-generator:[generator version] docker run --name rustici-generator-worker --env-file .env -e IS_WORKER=true -d 025066246552.dkr.ecr.us-east-1.amazonaws.com/rustici-generator:[generator version]
- Start the required containers:
Verify API Functionality:
- Connect to the API over
localhost
or its IP address to ensure it is working correctly. - Use the
/api/v1/health/check_up
endpoint to verify service health and its connections to other required services.
- Connect to the API over
Set Up Load Balancer (Optional):
- If applicable, configure a load balancer and point it to the API containers.
Configure DNS:
- Set up DNS for your load balancer.
- If using a single container (not recommended), configure DNS for that container.