Oscar Krause
cd4674caad
fixes
2024-06-21 19:35:42 +02:00
Oscar Krause
b0b627a3f0
Merge branch 'refs/heads/dev' into db
...
# Conflicts:
# .gitlab-ci.yml
# Dockerfile
# README.md
# app/main.py
# app/orm.py
# requirements.txt
2024-06-21 19:28:23 +02:00
Oscar Krause
c79455b84d
added way to include driver version in api
...
use `create_driver_matrix_json.py` to generate file in `static/driver_matrix.json`. Logging currently is disabled to not confuse users when file is missing. This is optional!
2024-06-21 19:01:33 +02:00
Oscar Krause
35fc5ea6b0
set log format
2024-06-21 18:59:23 +02:00
Oscar Krause
c9ac915055
code styling & comments
2024-06-13 20:34:45 +02:00
Oscar Krause
8c5850beda
migrated from deprecated "startup" to "lifespan" hook (fastapi)
2024-06-13 20:34:27 +02:00
Oscar Krause
0d9e814d0d
show if debug is enabled on app startup
2024-06-13 20:18:33 +02:00
Oscar Krause
5438317fb7
rearranged imports
2024-06-13 20:18:18 +02:00
Oscar Krause
21f19be8ab
code styling & improved logging
2024-06-13 20:16:51 +02:00
Oscar Krause
eff6aae25d
code styling
2024-06-13 19:53:57 +02:00
Oscar Krause
6473655e57
import fixes
2024-06-13 19:24:46 +02:00
Oscar Krause
248c70a862
Merge branch 'dev' into db
2023-06-12 15:19:28 +02:00
Oscar Krause
39a2408d8d
migrated api to database-config (Site, Instance)
2023-06-12 15:19:06 +02:00
Oscar Krause
18807401e4
orm improvements & fixes
2023-06-12 15:14:12 +02:00
Oscar Krause
5e47ad7729
fastapi openapi url
2023-06-12 15:13:53 +02:00
Oscar Krause
20448bc587
improved relationships
2023-06-12 15:13:29 +02:00
Oscar Krause
b4150fa527
implemented Site and Instance orm models including initialization
2023-06-12 12:42:13 +02:00
Oscar Krause
38e1a1725c
code styling
2023-06-12 12:40:10 +02:00
Oscar Krause
7e5f8b6c8a
implemented endpoint to remove expired leases
2023-06-12 10:48:00 +02:00
Oscar Krause
e42dc6aa86
code styling
2023-03-20 10:06:21 +01:00
Oscar Krause
59152f95e6
fixed - The `declarative_base()
` function is now available as sqlalchemy.orm.declarative_base()
2023-01-30 10:23:09 +01:00
Oscar Krause
62d347510d
fixed - sqlalchemy.exc.ArgumentError: Textual SQL expression '\nCREATE TABLE origin (\n\to...' should be explicitly declared as text('\nCREATE TABLE origin (\n\to...')
2023-01-30 10:22:18 +01:00
Oscar Krause
02276d5440
disabled openapi endpoints
2023-01-23 07:33:54 +01:00
Oscar Krause
f7ef8d76b6
fixed Origin.delete()
2023-01-23 07:12:02 +01:00
Oscar Krause
95427d430e
added startup script
2023-01-19 07:26:22 +01:00
Oscar Krause
c3ea0aa48c
added variable for client-token-expire-delta
2023-01-19 07:26:07 +01:00
Oscar Krause
91be7b226c
added some comments for default values
2023-01-19 07:25:44 +01:00
Oscar Krause
48c37987b2
fixed logging and added current timezone info
2023-01-18 14:23:25 +01:00
Oscar Krause
0ab5969d3a
fixes
2023-01-18 06:56:16 +01:00
Oscar Krause
b2e6fab294
fixes
2023-01-17 16:49:15 +01:00
Oscar Krause
3c19fc9d5b
implemented "lease_renewal" attribute as calculated value within what period of time the license must be renewed
2023-01-17 11:49:56 +01:00
Oscar Krause
a758d93970
main.py - fixed empty lease origin response
2023-01-17 11:18:07 +01:00
Oscar Krause
aecad82914
main.py - added confirmation to deleteOrigins()
2023-01-04 18:12:59 +01:00
Oscar Krause
32b05808c4
fixed "return" instead of "raise"
2023-01-04 10:14:00 +01:00
Oscar Krause
6c9ea63dc1
added variable for TOKEN_EXPIRE_DELTA
2023-01-04 10:08:17 +01:00
Oscar Krause
b839e6c2b3
code styling
...
- replaced 'json.loads' with 'json_loads'
- shortened 'JSONResponse' to 'JSONr'
- shortened 'HTMLResponse' to 'HTMLr'
- replaced HTTPException with JsonResponses
- added some error handing for invalid tokens
2023-01-04 10:04:52 +01:00
Oscar Krause
7b2428ea38
removed some debugging
2023-01-03 18:05:46 +01:00
Oscar Krause
ac811d5df7
added 'LEASE_EXPIRE_HOURS' variable for better debugging
2023-01-03 18:05:46 +01:00
Oscar Krause
d6cc6dcbee
fixes
2023-01-03 17:38:32 +01:00
Oscar Krause
18e9ab2ebf
fixes
2023-01-03 14:52:31 +01:00
Oscar Krause
ef1730f4fe
orm.py - added some docs
2023-01-03 14:20:13 +01:00
Oscar Krause
5a5ad0e654
removed 'scope_ref' from code checks because we only support one 'ALLOTMENT_REF', so we need no checks
2023-01-03 14:09:19 +01:00
Oscar Krause
0e3e7cbd3a
main.py - corrected leasing behaviour (migrated from 'LEASE_REF' to 'ALLOTMENT_REF')
2023-01-03 13:05:05 +01:00
Oscar Krause
bd5625af42
main.py - removed example responses
2023-01-03 13:02:37 +01:00
Oscar Krause
8f9d95056f
code styling - migrated direct dict access to '.get()'
2023-01-03 09:20:18 +01:00
Oscar Krause
2b8c468270
main.py - fixed missing 'LEASE_RENEWAL_PERIOD' on '/auth/v1/origin'
2023-01-03 07:25:09 +01:00
Oscar Krause
50e0dc8d1f
implemented '/leasing/v1/lessor/shutdown' for windows guests
2023-01-02 19:42:23 +01:00
Oscar Krause
8b934dfeef
fixed '/-/config' endpoint serialisation
2023-01-02 19:23:23 +01:00
Oscar Krause
4fb6243330
removed deprecated endpoints
...
- '/client-token' moved to '/-/client-token'
- '/status' moved to '/-/health' and '/-/config'
see README.md for more information
2023-01-02 19:18:32 +01:00
Oscar Krause
2e950ca6f4
implemented '/-/config' endpoint to list runtime environment variables
2023-01-02 19:14:25 +01:00