nicolargo
1624e66f48
Improve unittest #2757
2024-12-28 18:08:52 +01:00
nicolargo
ec0d5695a9
First test with Selenium
2024-12-28 09:00:50 +01:00
nicolargo
4bb39232fe
Merge branch 'develop' into issue2757
2024-12-27 22:09:20 +01:00
nicolargo
e14934a197
Update profiling file
2024-12-27 11:53:34 +01:00
nicolargo
c828f21753
Updata min-test
2024-12-26 10:54:50 +01:00
nicolargo
b491cbe42b
Make main.py comliant with PyTest (concerning args)
2024-12-26 10:48:50 +01:00
nicolargo
b6865d8cff
Remove now plugin in the left menu of the WebUI (in the make webui task)
2024-12-25 09:35:08 +01:00
nicolargo
0ed44f2c13
Make the glances/outputs/static/js/uiconfig.json generated automaticaly from the make webui task
2024-12-25 09:31:29 +01:00
nicolargo
318a61da6c
Add a target to start Glances with Htop features
2024-11-11 17:09:24 +01:00
nicolargo
42b87acb55
Update profiling
2024-11-10 13:59:42 +01:00
nicolargo
7ac7171a3f
Improve theme and refactor getDecoration for stats
2024-11-08 09:17:51 +01:00
Ariel Otilibili
dec419f443
Refactored `webui*` rules
...
* part of #2906
* output is unchanged.
```
$ git log --oneline -n1 --pretty=short
commit f2f97e2f (HEAD -> makefile)
Author: Ariel Otilibili <otilibil@eurecom.fr>
Refactored `webui*` rules
$ make webui -n >> /tmp/makefile; echo $?
0
$ make webui-audit -n >> /tmp/makefile; echo $?
0
$ make webui-audit-fix -n >> /tmp/makefile; echo $?
0
$ git switch develop
Switched to branch 'develop'
Your branch is up to date with 'origin/develop'.
$ git log --oneline -n1 --pretty=short
commit 24c87253 (HEAD -> develop, origin/develop, origin/HEAD)
Merge: 42af55b3 fa7fc5bd
Author: Nicolas Hennion <nicolashennion@gmail.com>
Merge pull request #2941 from ariel-anieli/refactor-alert
$ make webui -n >> /tmp/develop; echo $?
0
$ make webui-audit -n >> /tmp/develop; echo $?
0
$ make webui-audit-fix -n >> /tmp/develop; echo $?
0
$ diff /tmp/develop /tmp/makefile; echo $?
0
```
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-09-23 22:47:56 +02:00
nicolargo
76478959cc
Correct issue in Makefile
2024-08-24 09:32:01 +02:00
Ariel Otilibili
962ea850ed
Refactorized rules targetting `profiling-*` & `memory-profiling`
...
Part of #2906 :
* `profiling-*` share the same start banner
* used `OUT_DIR` for static outputs
* `TIMES` controls the number of iterations.
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-18 15:26:21 +02:00
Ariel Otilibili
13079a606b
Used patterns rules in `venv`, `venv-python`, & `venv-python`
...
* `venv-*-python` relies on the pattern `venv-%-python`
* `venv-(full|min|dev)` & `venv-*-upgrade` on `venv-%`
* macros `UPGRADE`, `PRE_COMMIT`, `VIRTUAL_ENV`, & `REQS` are rule switches
* `VIRTUAL_ENV` being evaluated at runtime from `DEFINE_VARS_FOR_TYPE`
* `make help` is unchanged.
```
$ make venv -n
virtualenv -p /usr/bin/python3 venv
virtualenv -p /usr/bin/python3 venv-min
virtualenv -p /usr/bin/python3 venv-dev
venv/bin/pip install -r requirements.txt; venv/bin/pip install -r optional-requirements.txt;
venv-min/bin/pip install -r requirements.txt;
venv-dev/bin/pip install -r dev-requirements.txt; venv-dev/bin/pip install -r doc-requirements.txt;
venv-dev/bin/pre-commit install --hook-type pre-commit
$ make venv-python -n
virtualenv -p /usr/bin/python3 venv
virtualenv -p /usr/bin/python3 venv-min
virtualenv -p /usr/bin/python3 venv-dev
$ make venv-upgrade -n
venv/bin/install install --upgrade pip
venv/bin/pip install --upgrade -r requirements.txt; venv/bin/pip install --upgrade -r optional-requirements.txt;
venv-min/bin/install install --upgrade pip
venv-min/bin/pip install --upgrade -r requirements.txt;
venv-dev/bin/install install --upgrade pip
venv-dev/bin/pip install --upgrade -r dev-requirements.txt; venv-dev/bin/pip install --upgrade -r doc-requirements.txt;
```
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-11 17:45:21 +02:00
Ariel Otilibili
feac10a84d
Renamed macros in Makefile
...
* `s/VENV/venv_full/; s/VENV_MIN/venv_min/; s/VENV_DEV/venv_dev/;`
* useful in subsequent changes
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-11 17:40:27 +02:00
Ariel Otilibili
a37010929d
Rules targetting `docker-*` are now built at runtime
...
* removed the macros `DOCKERFILE`, `TARGET`, & `DOCKER_TAG`
* introduced the macro `MAKE_DOCKER_BUILD_RULES`
* at runtime, `docker-*` are built from the `DISTROS` list: done using `eval` [1]
* `make help` is unchanged:
```
$ make | grep '\sdocker-'
make docker-alpine Generate local docker images (Alpine)
make docker-alpine-dev Generate local docker image (Alpine dev)
make docker-alpine-full Generate local docker image (Alpine full)
make docker-alpine-minimal Generate local docker image (Alpine minimal)
make docker-ubuntu Generate local docker images (Ubuntu)
make docker-ubuntu-dev Generate local docker image (Ubuntu dev)
make docker-ubuntu-full Generate local docker image (Ubuntu full)
make docker-ubuntu-minimal Generate local docker image (Ubuntu minimal)
$ make docker -n
docker buildx build --target full -f docker-files/alpine.Dockerfile -t glances:local-alpine-full .
docker buildx build --target minimal -f docker-files/alpine.Dockerfile -t glances:local-alpine-minimal .
docker buildx build --target dev -f docker-files/alpine.Dockerfile -t glances:local-alpine-dev .
docker buildx build --target full -f docker-files/ubuntu.Dockerfile -t glances:local-ubuntu-full .
docker buildx build --target minimal -f docker-files/ubuntu.Dockerfile -t glances:local-ubuntu-minimal .
docker buildx build --target dev -f docker-files/ubuntu.Dockerfile -t glances:local-ubuntu-dev .
```
[1] https://www.gnu.org/software/make/manual/html_node/Eval-Function.html
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-10 09:23:37 +02:00
Ariel Otilibili
ddfcf46dee
Renamed variables in `Makefile`; introduced the variable `DISTROS`
...
* needed for subsequent changes in `Makefile`
* `s/ALPINE_IMAGES/alpine_images/; s/UBUNTU_IMAGES/ubuntu_images/`
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-10 09:17:30 +02:00
Ariel Otilibili
f5c2d8ce36
Used pattern for rules targetting `run-docker-*`
...
`make help` & `make run-docker-*` are unchanged:
```
$ make | grep run-docker
make run-docker-alpine-dev Start Glances Alpine Docker dev in console mode
make run-docker-alpine-full Start Glances Alpine Docker full in console mode
make run-docker-alpine-minimal Start Glances Alpine Docker minimal in console mode
make run-docker-ubuntu-dev Start Glances Ubuntu Docker dev in console mode
make run-docker-ubuntu-full Start Glances Ubuntu Docker full in console mode
make run-docker-ubuntu-minimal Start Glances Ubuntu Docker minimal in console mode
$ make run-docker-alpine-minimal -n
docker run --rm -e TZ="" -e GLANCES_OPT="" --pid host --network host -v /run/user/1000/podman/podman.sock:/run/user/1000/podman/podman.sock:ro -v /var/run/docker.sock:/var/run/docker.sock:ro -it glances:local-alpine-minimal
$ make run-docker-alpine-full -n
docker run --rm -e TZ="" -e GLANCES_OPT="" --pid host --network host -v /run/user/1000/podman/podman.sock:/run/user/1000/podman/podman.sock:ro -v /var/run/docker.sock:/var/run/docker.sock:ro -it glances:local-alpine-full
$ make run-docker-alpine-dev -n
docker run --rm -e TZ="" -e GLANCES_OPT="" --pid host --network host -v /run/user/1000/podman/podman.sock:/run/user/1000/podman/podman.sock:ro -v /var/run/docker.sock:/var/run/docker.sock:ro -it glances:local-alpine-dev
$ make run-docker-ubuntu-dev -n
docker run --rm -e TZ="" -e GLANCES_OPT="" --pid host --network host -v /run/user/1000/podman/podman.sock:/run/user/1000/podman/podman.sock:ro -v /var/run/docker.sock:/var/run/docker.sock:ro -it glances:local-ubuntu-dev
$ make run-docker-ubuntu-full -n
docker run --rm -e TZ="" -e GLANCES_OPT="" --pid host --network host -v /run/user/1000/podman/podman.sock:/run/user/1000/podman/podman.sock:ro -v /var/run/docker.sock:/var/run/docker.sock:ro -it glances:local-ubuntu-full
$ make run-docker-ubuntu-minimal -n
docker run --rm -e TZ="" -e GLANCES_OPT="" --pid host --network host -v /run/user/1000/podman/podman.sock:/run/user/1000/podman/podman.sock:ro -v /var/run/docker.sock:/var/run/docker.sock:ro -it glances:local-ubuntu-minimal
```
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-08 12:28:58 +02:00
Ariel Otilibili
516c99e496
Used pattern for rules targetting `docker-*`
...
`make help` & `make docker-*` are unchanged:
```
$ make | grep -P '\sdocker-'
make docker-alpine Generate local docker images (Alpine)
make docker-alpine-dev Generate local docker image (Alpine dev)
make docker-alpine-full Generate local docker image (Alpine full)
make docker-alpine-minimal Generate local docker image (Alpine minimal)
make docker-ubuntu Generate local docker images (Ubuntu)
make docker-ubuntu-dev Generate local docker image (Ubuntu dev)
make docker-ubuntu-full Generate local docker image (Ubuntu full)
make docker-ubuntu-minimal Generate local docker image (Ubuntu minimal)
$ make docker-alpine -n
docker buildx build --target full -f docker-files/alpine.Dockerfile -t glances:local-alpine-full .
docker buildx build --target minimal -f docker-files/alpine.Dockerfile -t glances:local-alpine-minimal .
docker buildx build --target dev -f docker-files/alpine.Dockerfile -t glances:local-alpine-dev .
$ make docker-ubuntu -n
docker buildx build --target full -f docker-files/ubuntu.Dockerfile -t glances:local-ubuntu-full .
docker buildx build --target minimal -f docker-files/ubuntu.Dockerfile -t glances:local-ubuntu-minimal .
docker buildx build --target dev -f docker-files/ubuntu.Dockerfile -t glances:local-ubuntu-dev .
```
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-08 12:28:58 +02:00
Ariel Otilibili
1fef2594d2
Used pattern for rules targetting `test-*`
...
`make help` & `make test-*` are unchanged:
```
$ make | grep test
make test Run unit tests
make test-core Run core unit tests
make test-min Run core unit tests in minimal environment
make test-min-with-upgrade Upgrade deps and run unit tests in minimal environment
make test-restful Run Restful unit tests
make test-with-upgrade Upgrade deps and run unit tests
make test-xmlrpc Run XMLRPC unit tests
$ make test -n
venv/bin/python unittest-core.py
venv/bin/python unittest-restful.py
venv/bin/python unittest-xmlrpc.py
```
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-08 12:28:51 +02:00
Ariel Otilibili
0804d06c0b
Refactorized `make flatpak`
...
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
Ariel Otilibili
b03ea17a5f
Refactorized the rules targetting `docker-*`
...
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
Ariel Otilibili
6910e61bde
Refactorized `make semgrep`
...
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
Ariel Otilibili
a6fdc098b9
Refactorized the rules targetting `docs-*`
...
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
Ariel Otilibili
313612333c
Refactorized `trace-malloc` and the rules targetting `memory-*`
...
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
Ariel Otilibili
cad29145f1
Refactorized the rules targetting `profiling-*`
...
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
Ariel Otilibili
4dba2f13ad
Refactorized `format`, `lint`, & `codespell` rules
...
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
Ariel Otilibili
c171d7604e
Refactorized the rules targetting `test*`
...
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
Ariel Otilibili
658e318fd7
Refactorized the rules targetting `venv-*`
...
Addressed `venv-full-*`, `venv-min-*`, & `venv-dev-*`.
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
Ariel Otilibili
76cd7e63e2
Refactorized `make help`
...
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
Ariel Otilibili
020fe7a0b2
Placed phony targets under the same rule
...
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
Ariel Otilibili
c96c778883
Refactorized the rules targetting `run*`
...
* refactorized the rules targetting `run*`
* set up variables for subsequent refactorizations.
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
2024-08-07 07:37:48 +02:00
nicolargo
f603e8412c
Add another connector to snap
2024-07-07 18:47:46 +02:00
nicolargo
f4c7ca01fe
Correct codespell
2024-06-29 19:19:26 +02:00
Bharath Vignesh J K
00c662f870
chg: Makefile - use ruff & pre-commit
2024-05-17 04:13:26 +05:30
nicolargo
f2d7e13cd8
Improve tests by testing all the plugin/model.py methods #2757
2024-05-09 10:09:05 +02:00
nicolargo
fd3625826b
First work done for plugin model (stats only)
2024-05-07 15:26:16 +02:00
nicolargo
af4765db8a
Remove unitest shell script - Use Makefile instead
2024-05-07 14:07:08 +02:00
nicolargo
8e8d4ce89b
Rename unitest to unittest - Related to #2757
2024-05-07 14:01:36 +02:00
nicolargo
e8563a0fc4
Format code and update docs/webui
2024-05-07 11:49:55 +02:00
nicolargo
9121b77763
Add some profiling and upgrade CI to NodeJS 20
2024-05-06 11:55:37 +02:00
nicolargo
88fee9bc8e
Use buildx instead of build for local container images
2024-04-30 10:35:45 +02:00
nicolargo
1cd17d9614
Add the --hide-public-info option
2024-04-29 10:01:24 +02:00
nicolargo
2aa3f418df
Alert timestamp is incorrect #2591
2024-04-27 17:38:56 +02:00
nicolargo
c09d9256c7
Display date correctly in WebUI Alarm
2024-04-27 10:04:00 +02:00
nicolargo
43b355fdff
Update the Flame profiling
2024-03-09 16:50:26 +01:00
nicolargo
a5249a1893
Update Snapcraft
2024-02-03 09:59:31 +01:00
nicolargo
b3828f5497
Replace Bottle by FastAPI #2181
2023-12-16 15:00:04 +01:00
nicolargo
a3e08966b5
:Merge branch 'develop' into issue2181
2023-12-10 20:12:21 +01:00