Deploy a Streamlit App¶
This guide walks through creating a simple Streamlit app, committing it to Git, and deploying it to your server with Appliku.
1. Create a Directory¶
2. Python Virtual Environment¶
3. Install Streamlit¶
4. Create the App¶
Create app.py:
import streamlit as st
def main():
st.title("Deployed with Appliku")
st.write("This app is deployed with Appliku")
if __name__ == "__main__":
main()
5. Verify Locally¶
The app should open in your browser.
6. Create requirements.txt¶
7. Create a Production Run Script¶
Create run.sh — this passes the required arguments to Streamlit when deployed:
8. Push to GitHub¶
Create a .gitignore file:
Then initialize and push:
git init
git add .
git commit -m 'Initial commit'
git remote add origin git@github.com:your-username/your-repo.git
git push -u origin master
9. Deploy with Appliku¶
- Go to the Appliku dashboard
- Create an application from your GitHub repository
- Give it a name, select the repository and branch, select your server
- Click Create application
Set the SERVER_NAME Environment Variable¶
Before deploying, go to the Environment Variables tab in application settings.
Appliku gives each app a default domain: <app-name>.applikuapp.com. Add a variable:
| Variable | Value |
|---|---|
SERVER_NAME |
myapp.applikuapp.com (your app's domain) |
Click Save.
Configure the Process¶
In Application Settings → Processes, add a process:
- Name: web
- Command: bash run.sh
Click Save and Deploy.
Once deployment finishes, go to the application overview and open the app.
10. Set a Custom Domain¶
To use a custom domain, go to Application Settings → Domains.
In your DNS settings, point the A record for your domain to your server's IP address. Then update the SERVER_NAME environment variable to your custom domain and redeploy.