tigattack
d626493100
fix: Revert Dockerfile edits and lockfile changes
...
This reverts commits 8409b71857 and 78eb2b183e
2025-09-29 21:53:13 +01:00
Muhammad Ibrahim
b49ea6b197
Update PatchMon version to 1.2.7
...
- Updated agent script version to 1.2.7
- Updated all package.json files to version 1.2.7
- Updated backend version references
- Updated setup script version references
- Fixed agent file path issues in API endpoints
- Fixed linting issues (Node.js imports, unused variables, accessibility)
- Created comprehensive version update guide in patchmon-admin/READMEs/
2025-09-29 20:42:14 +01:00
Muhammad Ibrahim
78eb2b183e
Docker package-lock.json generation for each backend and frontend folder.
2025-09-29 17:20:13 +01:00
tigattack
840664c39e
chore: fixup package-lock, remove unused deps
2025-09-28 18:20:06 +01:00
tigattack
c886b812d6
chore: clarify auto-update feature
2025-09-27 00:52:04 +01:00
tigattack
be3fe52aea
fix(api): resolve duplicate key constraint errors in host package updates
2025-09-27 00:52:04 +01:00
tigattack
e3aa28a8d9
fix: login after signup
...
Also resolves entire user object being return to client, including password_hash... ⚠️
2025-09-26 20:17:09 +01:00
Muhammad Ibrahim
0c0446ad69
Added a few dashboard enhancements with Doughnut charts
2025-09-26 02:10:55 +01:00
Muhammad Ibrahim
527b0ccc3c
Fixed auto-update toggle to refresh upon save
2025-09-26 01:05:49 +01:00
tigattack
469107c149
fix: incorrect cardId
2025-09-26 00:24:32 +01:00
tigattack
22f6befc89
fix(backend): lint errors
2025-09-26 00:24:32 +01:00
tigattack
591389a91f
style(backend): fmt
2025-09-25 23:13:49 +01:00
Muhammad Ibrahim
a479003ba9
fix: return first_name and last_name in setup-admin and signup responses
...
- Add first_name and last_name to select clause in setup-admin endpoint
- Add first_name and last_name to select clause in signup endpoint
- Ensures frontend receives the name fields after user creation
- Fixes issue where first/last names don't populate in UI after setup
The data was being saved to database correctly but not returned in the API response, causing frontend to not display the names properly.
2025-09-24 20:17:36 +01:00
Muhammad Ibrahim
9f3016be57
deps: update all dependencies to latest non-deprecated versions
...
Frontend:
- ESLint: 8.53.0 → 9.17.0 (fixes deprecated warnings)
- React/React-DOM: 18.2.0 → 18.3.1
- Axios: 1.6.2 → 1.7.9
- Chart.js: 4.4.0 → 4.4.7
- Date-fns: 2.30.0 → 4.1.0 (major update)
- Express: 4.18.2 → 4.21.2
- HTTP-proxy-middleware: 2.0.6 → 3.0.3
- Lucide-react: 0.294.0 → 0.468.0
- React-router-dom: 6.20.1 → 6.31.0
- Add ESLint v9 flat config (eslint.config.js)
- Add required @eslint/js and globals dependencies
Backend:
- Prisma: 5.7.0 → 6.1.0
- Express: 4.18.2 → 4.21.2
- Dotenv: 16.3.1 → 16.4.7
- Express-rate-limit: 7.1.5 → 7.5.0
- Express-validator: 7.0.1 → 7.2.0
- Helmet: 7.1.0 → 8.0.0
- UUID: 9.0.1 → 11.0.3
- Winston: 3.11.0 → 3.17.0
- Nodemon: 3.0.2 → 3.1.9
Fixes npm warnings:
- rimraf < v4 deprecated
- inflight memory leaks
- glob < v9 deprecated
- @humanwhocodes packages deprecated
- ESLint v8 no longer supported
2025-09-24 19:50:50 +01:00
Muhammad Ibrahim
99aa79a6a4
Fixed authentication redirect upon signin using states
...
Finally fixed dashboard defaults for new user signups
2025-09-24 07:42:15 +01:00
Muhammad Ibrahim
73761d8927
fixed dashboard defaults via server.js config
2025-09-24 07:07:38 +01:00
Muhammad Ibrahim
9889083900
reverted the removal of schema migration files to make it production save in order to not mess up previous instances
2025-09-24 03:05:22 +01:00
Muhammad Ibrahim
acb30f22bd
Removed migration settings from earlier whic hwere messing with the logic of new dashboard layout system. Now has a single source of truth based on what the defaults should be in server.js
2025-09-24 02:54:44 +01:00
Muhammad Ibrahim
3a0b564a6f
Fixed permissions issues
...
Created default user role
modified server.js to check if roles of admin/user is present
modified server.js to check dashboard cards
set up default dashboard cards to show
2025-09-24 02:33:26 +01:00
tigattack
c3aa5534f3
fix: improve proxy config
2025-09-22 23:42:00 +01:00
tigattack
bf2ea908f4
refactor(docker): rework docker
...
- Move Docker files to own directory (tidier since I added several more files)
- Optimise images and reduce size
- Uses multi-stage builds
- Optimises layer efficiency
- Uses NGINX as base for frontend
- Sets default env vars
- Uses tini for proper signal handling
2025-09-22 23:42:00 +01:00
tigattack
001b234ecc
fix(backend): set imported agent versions as current
...
Fixes agent installation script failing with "No agent version available" error
- Auto-imported agent versions now marked as current/default appropriately
- First imported version becomes both current and default
- Newer versions become current (but not default)
- Added concurrent database updates with Promise.all()
- Fixed agent download endpoint fallback to filesystem when no DB versions exist
2025-09-22 23:41:53 +01:00
tigattack
d300922312
refactor(backend): make /agent/download route more resilient
...
* Fixes early 404 return
* Fixes filename when agent version undefined
* Correctly returns 500 when error occurs
2025-09-22 22:23:54 +01:00
tigattack
20ff5b5b72
refactor(backend): update DB wait env var names
2025-09-22 22:23:54 +01:00
tigattack
5e6a2d863c
fix(backend): update settings log msgs
2025-09-22 22:23:54 +01:00
tigattack
ab46b0138b
feat(backend): strip default ports from serverUrl
2025-09-22 22:23:54 +01:00
tigattack
9cb5cd380b
feat(backend): add settings service with env var handling
...
New features:
* Settings initialised on startup rather than first request
* Settings are cached in memory for performance
* Reduction of code duplication/defensive coding practices
2025-09-22 22:23:54 +01:00
tigattack
517b5cd7cb
feat(backend): make requests to health endpoint debug log level
...
avoids spam in docker
2025-09-22 22:23:54 +01:00
tigattack
5dafe34322
feat(backend): add option to log to console
...
Enabled by `PM_LOG_TO_CONSOLE=true`
2025-09-22 22:23:54 +01:00
tigattack
677d3b4df1
feat(backend): wait for DB on start
2025-09-22 22:23:54 +01:00
tigattack
c3365fedb2
fix: conflate frontend_url and server_url
2025-09-22 22:23:54 +01:00
Muhammad Ibrahim
f23f075e41
Added more dashboard cards
...
Fixed permissions roles creation bug
On initial deployment, made it so the agent being populated will be set as default and current
Fixed host detail to include package numbers
Added ability to add full name
- fixed loads of other bugs caused by camelcase to snake_Case migration
2025-09-22 21:31:14 +01:00
Muhammad Ibrahim
9b76d9f81a
don't think the setting of agent update is neede din the env.example as its all done via the server itself
2025-09-22 02:43:58 +01:00
Muhammad Ibrahim
64d9c14002
Sorted the issue out with installation file not being found upon deployment. Ensured jq dependancy is installing in version 1.2.5 and above of the installation commands
2025-09-22 02:39:22 +01:00
Muhammad Ibrahim
9a01d27d8b
Removed populate-agent-version.js as now agent is being imported if newer than existing upon service start
2025-09-22 02:30:12 +01:00
Muhammad Ibrahim
d72f96b598
Improved Agent version import upon service start
2025-09-22 02:22:25 +01:00
Muhammad Ibrahim
8f8b23ccf1
Fixed agent version display issue
2025-09-22 01:46:35 +01:00
Muhammad Ibrahim
1392976a7b
Fixed agent version display issue
2025-09-22 01:45:27 +01:00
Muhammad Ibrahim
797be20c45
Created toggle for enable / disable user signup flow with user role
...
Fixed numbers mismatching in host cards
Fixed issues with the settings file
Fixed layouts on hosts/packages/repos
Added ability to delete multiple hosts at once
Fixed Dark mode styling in areas
Removed console debugging messages
Done some other stuff ...
2025-09-22 01:06:18 +01:00
Muhammad Ibrahim
697da088d4
Fixed admin count endpoint
2025-09-21 22:42:47 +01:00
Muhammad Ibrahim
38d299701d
Added security restrictions to admin count endpoint and force admin setup for testing
2025-09-21 22:31:07 +01:00
Muhammad Ibrahim
7ff051be3e
Implemented first-time admin registration flow if no admin present
2025-09-21 22:08:07 +01:00
Muhammad Ibrahim
2de80f0c06
Updated frontend to snake_case and fixed bugs with some pages that were not showing. Fixed authentication side.
2025-09-21 20:27:47 +01:00
AdamT20054
a96439596d
Script actually downloads on deb systems (i only use deb, sm1 else will have to test the other distros)
2025-09-21 07:54:43 +01:00
AdamT20054
d2bf201f1e
Fix script path in hostRoutes to correct installation script location. **Might break non docker installs?**
2025-09-21 07:35:10 +01:00
AdamT20054
8722bd170f
Fix updating the server URL in the dashboard not updatinng.
2025-09-21 07:11:58 +01:00
AdamT20054
fd76a9efd2
Refactor authentication and routing code to use consistent naming conventions for database fields.
...
Do NOT update the schema like that again for the love of god.
2025-09-21 06:59:39 +01:00
AdamT20054
584e5ed52b
Refactor database model references to use consistent naming conventions and update related queries
2025-09-21 06:13:05 +01:00
AdamT20054
c5ff4b346a
Refactor agent version handling to use consistent naming and add download URL
2025-09-21 05:19:09 +01:00
AdamT20054
cc9f0af1ac
Fixed my cp fuckup.
2025-09-21 04:30:54 +01:00