Before starting the project, please ensure your system meet the below prerequisite.
- Docker installed before running this app. Please run the below command to verify Docker is installed in your system
`docker --version`
If it is not installed, please refer to this Docker installation guide.
- Greenplum (version 7) database is up and running
- Download the source code from Github
git clone https://github.com/ahmedrachid/streamlit-chatbot-greenplum.git
- Go to the project repository
cd streamlit-chatbot-greenplum
- Open the app.py file and change the database credential if required
vim app.py
Change this section: postgres://<db-user>:<password>@<db-ip>:<db-port>/<databasename>
- Build the docker image. The below command is to build a docker image with name streamline-chatbot-greenplum with the latest version
docker build -t streamlit-chatbot-greenplum .
- Verify image
streamlit-chatbot-greenplum
is built successfully
docker images
- Run the docker image streamlit-chatbot-Greenplum
docker run -p 8501:8501 streamlit-chatbot-greenplum
- Go to the browser and open the web link.
Note: the IP address is the IP that your VM / local env uses. For example,
http://35.189.1.42:8501
Please refer to this blog for detailed explaination and use case.