fixed bug with spreadsheet import

This commit is contained in:
GotthardG 2024-12-10 16:28:44 +01:00
parent 69bf5b5a6e
commit 672574c755
4 changed files with 9 additions and 7 deletions

View File

@ -25,7 +25,7 @@ cert_path = config['ssl_cert_path']
key_path = config['ssl_key_path']
# Generate SSL Key and Certificate if not exist (only for development)
if environment == 'development':
if environment == 'dev':
Path("ssl").mkdir(parents=True, exist_ok=True)
if not Path(cert_path).exists() or not Path(key_path).exists():
ssl_heidi.generate_self_signed_cert(cert_path, key_path)
@ -77,10 +77,10 @@ if __name__ == "__main__":
cert_path = "ssl/cert.pem"
key_path = "ssl/key.pem"
if environment == 'testing':
if environment == 'test':
cert_path = "ssl/mx-aare-test.psi.ch.pem"
key_path = "ssl/mx-aare-test.psi.ch.key"
# Run the application with appropriate SSL setup
uvicorn.run(app, host="127.0.0.1", port=8000, log_level="debug",
uvicorn.run(app, host="0.0.0.0", port=8000, log_level="debug",
ssl_keyfile=key_path, ssl_certfile=cert_path)

View File

@ -4,6 +4,6 @@
"OPENAPI_URL": "https://mx-aare-test.psi.ch:8000/openapi.json",
"SCHEMA_PATH": "./src/openapi.json",
"OUTPUT_DIRECTORY": "./openapi",
"SSL_KEY_PATH": "/home/jungfrau/heidi-v2/backend/app/ssl/mx-aare-test.psi.ch.key",
"SSL_CERT_PATH": "/home/jungfrau/heidi-v2/backend/app/ssl/mx-aare-test.psi.ch.pem"
"SSL_KEY_PATH": "/home/jungfrau/heidi-v2/backend/ssl/mx-aare-test.psi.ch.key",
"SSL_CERT_PATH": "/home/jungfrau/heidi-v2/backend/ssl/mx-aare-test.psi.ch.pem"
}

View File

@ -1,5 +1,5 @@
{
"name": "mheidi-frontend-v2",
"name": "heidi-frontend-v2",
"private": true,
"version": "0.0.0",
"type": "module",

View File

@ -13,6 +13,8 @@ export default defineConfig(({ mode }) => {
https: {
key: env.VITE_SSL_KEY_PATH,
cert: env.VITE_SSL_CERT_PATH,
}
},
host: true, // This allows hosting on network interfaces
port: 5173 // Optional: Specify a custom port (default is 5173)
}}
});