Add some previously uncommitted stuff
This commit is contained in:
Binary file not shown.
Binary file not shown.
@@ -1,4 +1,7 @@
|
|||||||
from applets.welcome import bp
|
from applets.welcome import bp
|
||||||
|
from flask import Flask, request, session, redirect, \
|
||||||
|
url_for, render_template, flash, Blueprint
|
||||||
|
import dmm.lsblk as lsblk
|
||||||
|
|
||||||
|
|
||||||
@bp.route('/welcome',methods=['GET', 'POST', 'PUT'])
|
@bp.route('/welcome',methods=['GET', 'POST', 'PUT'])
|
||||||
@@ -7,8 +10,10 @@ def welcome_index():
|
|||||||
The page you'd get if you access the root of
|
The page you'd get if you access the root of
|
||||||
this app in a browser.
|
this app in a browser.
|
||||||
"""
|
"""
|
||||||
return ("Welcome to System Installer Daemon POC <br />"
|
blkid = lsblk.list_scsi_devices()
|
||||||
"This is the Welcome Index")
|
return render_template('welcome.html', blkid=blkid)
|
||||||
|
#return ("Welcome to System Installer Daemon POC <br />"
|
||||||
|
# "This is the Welcome Index")
|
||||||
|
|
||||||
|
|
||||||
@bp.route('/welcome2')
|
@bp.route('/welcome2')
|
||||||
|
|||||||
1
src/applets/welcome/static/welcome.css
Normal file
1
src/applets/welcome/static/welcome.css
Normal file
@@ -0,0 +1 @@
|
|||||||
|
test:
|
||||||
1
src/static/welcome.css
Normal file
1
src/static/welcome.css
Normal file
@@ -0,0 +1 @@
|
|||||||
|
test:
|
||||||
@@ -9,6 +9,7 @@ from flask import Flask, request, session, redirect, \
|
|||||||
url_for, render_template, flash, Blueprint
|
url_for, render_template, flash, Blueprint
|
||||||
from waitress import serve
|
from waitress import serve
|
||||||
import logging
|
import logging
|
||||||
|
import dmm.lsblk as lsblk
|
||||||
|
|
||||||
# configuration
|
# configuration
|
||||||
VERSION = "0.00"
|
VERSION = "0.00"
|
||||||
@@ -45,6 +46,10 @@ if DEV_MODE == "1":
|
|||||||
logger.debug("logger set to DEBUG")
|
logger.debug("logger set to DEBUG")
|
||||||
|
|
||||||
|
|
||||||
|
# Justtry doing something with dmm
|
||||||
|
lsblk.list_scsi_devices()
|
||||||
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
if DEV_MODE:
|
if DEV_MODE:
|
||||||
serve(app,
|
serve(app,
|
||||||
|
|||||||
33
src/templates/welcome.html
Normal file
33
src/templates/welcome.html
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
<!doctype html>
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8">
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<link href="/static/welcome.css" rel="stylesheet">
|
||||||
|
<script src="https://cdn.tailwindcss.com"></script>
|
||||||
|
<script>
|
||||||
|
tailwind.config = {
|
||||||
|
theme: {
|
||||||
|
extend: {
|
||||||
|
colors: {
|
||||||
|
clifford: '#da373d',
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<div class="bg">
|
||||||
|
</div>
|
||||||
|
<h1 class="text-3xl font-bold underline">
|
||||||
|
Hello world!
|
||||||
|
</h1>
|
||||||
|
|
||||||
|
<div class="lg:content-auto">
|
||||||
|
Welcome to system installer daemon
|
||||||
|
BLK is {{ blkid }}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
Reference in New Issue
Block a user