dot / app.py
Ramesh-vani's picture
Update app.py
f6902d8 verified
import subprocess
import sys
try:
from flask import Flask, render_template_string
except ImportError:
subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'flask'])
from flask import Flask, render_template_string
app = Flask(__name__)
@app.route('/')
def home():
html_content = '''
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<style>
body {
margin: 0;
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
background-color: black;
}
.dot {
width: 20px;
height: 20px;
background-color: red;
border-radius: 50%;
}
</style>
<title>Red Dot</title>
</head>
<body>
<div class="dot"></div>
</body>
</html>
'''
return render_template_string(html_content)
if __name__ == '__main__':
app.run(debug=True,host='0.0.0.0', port=7860)