~ Note: These blogs can be found in the SugarLabs website as well. The content is the same in both places :) ~
A record
creation and launch of ai.sugarlabs.orgport 8000
to port 443
, enabling HTTPS access.server {
server_name ai.sugarlabs.org;
location / {
proxy_pass http://localhost:8000;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
listen 443 ssl; # managed by Certbot
ssl_certificate /etc/letsencrypt/live/ai.sugarlabs.org/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/ai.sugarlabs.org/privkey.pem; # managed by Certbot
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
}
server {
listen 443 ssl;
server_name ai.sugarlabs.org;
ssl_certificate /etc/letsencrypt/live/ai.sugarlabs.org/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/ai.sugarlabs.org/privkey.pem;
location / {
proxy_pass http://localhost:8000;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
A record
was created pointing to the static IP of our EC2 instance. The service can now be accessed at : ai.sugarlabs.org[email protected]
. The Github OAuth is yet to be done. (If any changes / support is needed related to Google OAuth in the future, you can reach out to me at [email protected])So finally SugarAI is live!! You can access it via the API. For docs take a look at the README.
network_status.py
script or a function to check if user is connected to internet and decide which brain to use for chatbot (LLM / SLM) based on connectivity.Thank you to my mentors, the Sugar Labs community, and fellow GSoC contributors for their ongoing support. Special thanks to Krish, who also helped with the deployment and development of SugarAI.
Powered by Not An SSG 😎