Portfolio/app/app.py
2024-12-30 17:07:58 -06:00

43 lines
1.2 KiB
Python

from flask import Flask, render_template, send_from_directory
app = Flask(__name__, static_url_path='', static_folder='static')
# Define individual routes for each file
@app.route('/static/Compialer.png')
def serve_compialer():
return send_from_directory('static/images', 'Compialer.png')
@app.route('/static/cpu-emulator.png')
def serve_cpu_emulator():
return send_from_directory('static/images', 'cpu-emulator.png')
@app.route('/static/dll-extractor.png')
def serve_dll_extractor():
return send_from_directory('static/images', 'dll-extractor.png')
@app.route('/static/game-engine.png')
def serve_game_engine():
return send_from_directory('static/images', 'game-engine.png')
@app.route('/static/gcml.png')
def serve_gcml():
return send_from_directory('static/images', 'gcml.png')
@app.route('/static/net-scanner.png')
def serve_net_scanner():
return send_from_directory('static/images', 'net-scanner.png')
@app.route('/static/wictra-website.png')
def serve_wictra_website():
return send_from_directory('static/images', 'wictra-website.png')
@app.route('/')
def serve_index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0', port=80)