Girish Ramakrishnan
be2775e12e
memoryLimit: redefine to not include swap
...
Currently, we allocate 50% as RAM and 50% as swap. The manifest is
usually quite conservative on memory values. This means that we set
up a system where the app is applying memory pressure almost immediately.
This then swaps things randomly and increases cpu usage (kswapd shows
up in the profile).
To rethink the whole situation: we should not cap apps with a swap limit at all.
The memory hard limit is what is important. By redefining memoryLimit , we are
doubling every container's memory and it's good that we over allocate this.
2024-04-09 18:59:40 +02:00
Girish Ramakrishnan
b66e77a2d8
Fix crash when system has no swap
2024-03-22 10:39:35 +01:00
Girish Ramakrishnan
13e62bc738
logs: use stream.destroy() instead of custom hooks
2024-02-24 17:35:37 +01:00
Girish Ramakrishnan
0e83658aa3
make sudo commands terminate properly
...
sudo forks and execs the program. sudo also hangs around as the parent of the program waiting on the program and also forwarding signals.
sudo does not forward signals when the originator comes from the same process group. recently, there has been a change where it will
forward signals as long as sudo or the command is not the group leader (https://www.sudo.ws/repos/sudo/rev/d1bf60eac57f )
for us, this means that calling kill from this node process doesn't work since it's in the same group (and ubuntu 22 doesn't have the above fix).
the workaround is to invoke a kill from a different process group and this is done by starting detached
another idea is: use "ps --pid cp.pid -o pid=" to get the pid of the command and then send it signal directly
see also: https://dxuuu.xyz/sudo.html
2024-02-24 16:19:07 +01:00
Girish Ramakrishnan
a6f078330f
shell: no need to promise scoping
2024-02-21 19:40:27 +01:00
Girish Ramakrishnan
14c9260ab0
shell: exec encoding is utf8 by default and no shell
...
explicitly mark calls that require the shell
2024-02-21 17:47:25 +01:00
Girish Ramakrishnan
9b94cf18d0
convert more execSync to async
2024-02-21 11:00:12 +01:00
Girish Ramakrishnan
b51071155a
Use the async shell exec
2024-02-20 22:57:36 +01:00
Girish Ramakrishnan
176baa075f
Fix some typos
2024-01-30 11:53:54 +01:00
Johannes Zellner
2d1e0ec890
Ensure we never set more memory than swap for containers
2024-01-24 15:54:57 +01:00
Girish Ramakrishnan
44be454a1e
system: return activation time if we have it
2023-12-04 01:41:56 +01:00
Girish Ramakrishnan
cbf1b47332
system: merge info and dmi routes
...
also return uptimeSecs instead of abstract date
2023-12-04 01:11:26 +01:00
Girish Ramakrishnan
eb64bd296a
system: return uptime and reboot required
2023-12-04 00:46:12 +01:00
Girish Ramakrishnan
72083f59cd
system: dmi information
2023-12-04 00:31:18 +01:00
Girish Ramakrishnan
8a20b603f5
system: cpu route
2023-12-04 00:23:25 +01:00
Girish Ramakrishnan
470417fcbe
more test fixing
2023-12-03 21:18:16 +01:00
Johannes Zellner
1f8c55f536
Add docker-volume disk usage info
2023-10-17 16:51:57 +02:00
Girish Ramakrishnan
c62091b077
system: getUbuntuVersion
2023-08-11 21:47:49 +05:30
Girish Ramakrishnan
1cdd528b45
separate the provision status and cloudron status
2023-08-10 22:29:47 +05:30
Johannes Zellner
5ef8d8d3b0
Add uuid to block device listing
2023-08-08 12:34:19 +02:00
Girish Ramakrishnan
2cdbf4d2c5
move server routes into /system
2023-08-04 13:42:21 +05:30
Girish Ramakrishnan
e73b75e4b5
settings: move backup settings
2023-08-04 11:54:12 +05:30
Girish Ramakrishnan
e65c1fb718
graphs: show old backup size and location if > 1GB
2023-08-01 18:44:27 +05:30
Girish Ramakrishnan
0722692210
graphs: always show /var/backups size
...
often this has old backups
2023-08-01 17:38:48 +05:30
Girish Ramakrishnan
54e33a0ece
graphs: no disk speed for network disks
2023-08-01 17:17:10 +05:30
Girish Ramakrishnan
295c74a7a9
notifications: use clearAlert to clear disk space message
2023-03-26 17:20:58 +02:00
Girish Ramakrishnan
8205beeabf
notifications: make update alerts non-persistent
...
once acked, they remain acked. no need to keep nagging the user about them.
2023-03-26 15:12:39 +02:00
Johannes Zellner
10e07fa300
Add disk speeds to disk usage data
2023-01-27 21:05:25 +01:00
Girish Ramakrishnan
67cde5a62c
du: fix crash when filesystem is cifs/nfs/sshfs
2022-12-08 08:52:50 +01:00
Johannes Zellner
d126f056fc
Start with a default to not fail if no swap is present
2022-12-05 12:20:42 +01:00
Johannes Zellner
35ea3b1575
Also include potential swap files in the disk usage stats
2022-11-22 12:15:17 +01:00
Girish Ramakrishnan
549cb92ce7
return swap listing in the disk route
2022-11-04 15:25:12 +01:00
Girish Ramakrishnan
17c7cc5ec7
Remove external df module
...
It has some parsing issues with locale
2022-10-18 19:56:18 +02:00
Girish Ramakrishnan
eb5c90a2e7
du: do not crash when app dir is missing
...
this can happen when the app is installing/uninstalling
2022-10-13 23:35:01 +02:00
Girish Ramakrishnan
4fe0402735
box data is separate from mail data already
2022-10-12 11:59:28 +02:00
Girish Ramakrishnan
fa7c0a6e1b
add disks tests
2022-10-12 10:45:29 +02:00
Girish Ramakrishnan
edb6ed91fe
add disk usage task
2022-10-12 10:26:21 +02:00
Girish Ramakrishnan
a3f7ce15ab
system: rework disks api to return by filesystem
2022-10-12 09:42:14 +02:00
Girish Ramakrishnan
3c963329e9
du: exclude option
2022-10-11 23:14:50 +02:00
Girish Ramakrishnan
656f3fcc13
add system.du
2022-10-11 23:06:54 +02:00
Johannes Zellner
02d95810a6
Do not include proxy apps in graphs
2022-08-05 14:38:57 +02:00
Girish Ramakrishnan
544ca6e1f4
initial xfs support
2022-06-08 10:58:00 -07:00
Girish Ramakrishnan
dddc5a1994
migrate app dataDir to volumes
2022-06-02 16:29:01 -07:00
Girish Ramakrishnan
ad3dbe8daa
mail: keep mail backups separately from box backups
...
part of #717
2021-09-26 21:47:24 -07:00
Girish Ramakrishnan
42774eac8c
docker.js and services.js: async'ify
2021-08-26 18:23:31 -07:00
Girish Ramakrishnan
77f5cb183b
merge appdb.js into apps.js
2021-08-23 15:35:38 -07:00
Girish Ramakrishnan
411cc7daa1
merge settingsdb into settings code
2021-08-19 17:45:40 -07:00
Girish Ramakrishnan
7d3270e51a
notifications: do not jump json blob for out of disk space
2021-06-23 23:41:55 -07:00
Girish Ramakrishnan
8da4eaf4a3
fix tests
2021-06-03 16:08:39 -07:00
Girish Ramakrishnan
fc52cd7e0c
volumes: async'ify
2021-05-12 11:46:04 -07:00