Commit Graph

686 Commits

Author SHA1 Message Date
xbgmsharp
fc9fb8769a Update monitorin offline and online to use send_notification_fn 2022-12-17 23:33:19 +01:00
xbgmsharp
3432d358d3 Add reverse_geoip_py_fn python3 function 2022-12-17 23:32:23 +01:00
xbgmsharp
340bda704e Update publick.email_templates table 2022-12-17 23:17:15 +01:00
xbgmsharp
54156ae7c9 Update api.metrics to support 2 dimension hypertable. Update api.metadata tablesto with updated_at handle by moddatetime extension 2022-12-17 23:15:22 +01:00
xbgmsharp
4c4f0bbd37 Update permision for role grafana_auth and grafana 2022-12-17 23:13:18 +01:00
xbgmsharp
b58fce186a Rename grafan container to app 2022-12-12 23:52:24 +01:00
xbgmsharp
c6c78ecffc Update pgsql/timescale grafana source 2022-12-12 23:51:57 +01:00
xbgmsharp
db0e493900 Add grafana config,dashboards,provisioning 2022-12-12 22:28:01 +01:00
xbgmsharp
dea5b8ddf7 Add grafana 2022-12-12 22:12:22 +01:00
xbgmsharp
e9e63fad50 Add ERD description 2022-12-12 22:11:52 +01:00
xbgmsharp
8b45a171e8 Update vessel_role permission for new api.metrics trigger 2022-12-12 16:21:42 +01:00
xbgmsharp
a0216dad6a Refactor metrics_trigger_fn on api.metrics trigger to avoid multiple stay or logbook active 2022-12-09 12:35:18 +01:00
xbgmsharp
ca5bffd88f Add tables MMSI MID Code Filtered by Flag of Registration 2022-12-09 12:34:23 +01:00
xbgmsharp
1dbf71064e Update reverse_geocode_py_fn to return always data if name is null then fallback to address field road,neighbourhood,suburb 2022-12-09 12:33:00 +01:00
xbgmsharp
6888953cbb Add OTP notification, Add OTP DELETE, Add api.pushover_subscribe_link_fn, Add auth.telegram_session_exists_fn 2022-12-06 21:41:14 +01:00
xbgmsharp
105d6b9113 Add AIS Ship Types tables 2022-12-06 21:40:09 +01:00
xbgmsharp
0c2e4b1d83 cron_vaccum_fn does not work 2022-12-05 23:31:45 +01:00
xbgmsharp
f8b1fb472a Remove mmsi dependency, enforce add check valid longitude,latitude, ignore silently NULL longitude,latitude 2022-12-05 23:29:44 +01:00
xbgmsharp
613ac5e29a Remove mmsi dependency and ensure longitude,latitude exist prior post processing 2022-12-05 23:23:51 +01:00
xbgmsharp
5ce5b606e9 Remove mmsi dependency, update to use vessel_id instead 2022-12-05 23:19:58 +01:00
xbgmsharp
0f59a31cdc Fix SQL query IMMUTABLE STRICT 2022-12-05 23:17:45 +01:00
xbgmsharp
58407a84e9 Update auth.vessel.mmsi type to NUMERIC and add conistraint and remove dependency 2022-12-05 23:15:44 +01:00
xbgmsharp
9ae9553254 Allow to set password from env for role grafana_auth 2022-12-05 14:56:53 +01:00
xbgmsharp
494cc9a571 Add new function urlencode_py_fn()
Update debug for send_pushover and send_telegram
2022-12-02 14:36:01 +01:00
xbgmsharp
dbd29ca58a Add new variable PGSAIL_PUSHOVER_APP_URL 2022-12-02 11:50:33 +01:00
xbgmsharp
00cdd7ca18 Refactor web user notification
Add new cron job cron_new_notification
Add public.cron_process_new_notification_fn function
Add public.process_notification_queue_fn function
Update messages template table, align cron name with template notification name
2022-12-02 11:22:28 +01:00
xbgmsharp
34fe0898b2 Split public schame in file by type tables,functions and functions in python 2022-11-30 21:15:47 +01:00
xbgmsharp
3522d3b9d7 Update email type to CITEXT, https://www.postgresql.org/docs/current/citext.html 2022-11-30 21:12:49 +01:00
xbgmsharp
d4f79e7f71 A large commit with new features (pushover, telegram, otp) and fixes
Update reverse_geocode_py_fn validate input
Update email_templates add new message type for pushover, telegram and otp
Update send_email_py_fn mkae email From field humain friendly
Add send_pushover_py_fn python send pushover message
Add send_telegram_py_fn python send telegram message
Add process_account_otp_validation_queue_fn process handle for email validation
Add send_notification_fn refactor notification system to support email,pushover,telegram
Update public.process_queue table
Add new_account_otp_validation_entry_fn trigger
Update postgrest pre db check_jwt to support row security level
2022-11-29 23:50:59 +01:00
xbgmsharp
4df4fa993a U 2022-11-29 23:25:51 +01:00
xbgmsharp
94f79080aa Add new app paremeters for pushover and telegram
PGSAIL_PUSHOVER_APP_TOKEN -> app.pushover_app_token
PGSAIL_TELEGRAM_BOT_TOKEN -> app.telegram_bot_token
2022-11-29 23:24:39 +01:00
xbgmsharp
1a5c0f10c3 Fixed typo in vesselid for auth.vessels table 2022-11-29 23:20:01 +01:00
xbgmsharp
e6309875fb Limit connection to database to 100 2022-11-29 23:19:31 +01:00
xbgmsharp
2e269b9424 Update RSL to 'user.email' settings
Remove dependency to jwt for auth tables
2022-11-29 22:51:07 +01:00
xbgmsharp
40e25b1f8c Add Email OTP validation API endpoint 2022-11-29 22:49:50 +01:00
xbgmsharp
9eec9ad355 Add description to accounts and vessels triggers with moddatetime 2022-11-29 10:39:26 +01:00
xbgmsharp
90d2c3b3a0 Update OTP Code to a random 6 digit 2022-11-29 10:38:45 +01:00
xbgmsharp
d25f31ce0b Add a every 6 minute job cron_process_new_account_otp_validation_queue_fn, delay from cron_new_account 2022-11-28 22:30:55 +01:00
xbgmsharp
c8e722283c Fixed ERD images link 2022-11-28 22:18:55 +01:00
xbgmsharp
2095e9b561 Update images links 2022-11-28 22:13:53 +01:00
xbgmsharp
73addfa928 publish initial release of Entity-Relationship Diagram (ERD) 2022-11-28 22:11:13 +01:00
xbgmsharp
345f190f4e Add CRON for new account pending otp validation notification 2022-11-28 21:51:27 +01:00
xbgmsharp
0682f06ae9 Update update_user_preferences_fn to allow email or telegram user auth (to be improve) 2022-11-28 21:49:57 +01:00
xbgmsharp
8bc0fdaf17 Fixed auth.vessels table creation 2022-11-28 21:48:30 +01:00
xbgmsharp
ab1afeee42 Enable telegram bot auth 2022-11-28 21:47:28 +01:00
xbgmsharp
b6d60dd0d5 Update grafana_auth role description 2022-11-28 18:17:07 +01:00
xbgmsharp
295d0a0a5e Fix SQL vquery 2022-11-28 15:26:43 +01:00
xbgmsharp
a68a0ee3e3 Refactor auth tables (accounts,vessels)
Add unique userid column for jwt auth
Add unique vesselid column for jwt auth
Add new extensions citext,moddatetime
Update email column to citext type for fast queries
Add updated_at column to trak changed managed by moddatetime extension
Update index tables (accounts,vessels)
2022-11-25 23:14:30 +01:00
xbgmsharp
ea7301e1ed Add primary support for new stays,moorages,stats,timelapse views 2022-11-25 22:37:08 +01:00
xbgmsharp
98f5d75429 Add grafana_auth apache proxy auth role 2022-11-25 22:33:54 +01:00