Laurence Jones
342e7f5272
Cscli Explain Stdin ( #1597 )
...
Allow `cscli explain` to rely on stdin
2022-06-23 11:51:43 +02:00
mmetc
628d7be1d8
simplify err.Error() to err when used in printf context ( #1603 )
2022-06-22 15:53:53 +02:00
Thibault "bui" Koechlin
a6ed08b239
Add alerts and decisions metrics, LAPI and agent timing prom metrics ( #1546 )
2022-06-22 11:14:34 +02:00
AlteredCoder
0a39066f9d
Fix #1552 ( #1569 )
2022-06-22 10:29:02 +02:00
Laurence Jones
a1d5a02646
Cscli explain use temp dir ( #1598 )
...
* Write to temp dir instead of CWD
2022-06-22 10:27:43 +02:00
mmetc
d71279f023
added flag crowdsec --warning ( #1461 )
2022-06-22 09:38:23 +02:00
mmetc
c78c833400
CI: colored test output, colored crowdsec and crowdsec-api logs, full final db dump for mysql and sqlite ( #1596 )
...
* github-ci: color unit test output and logs
* new config option: force_color_logs (useful in CI)
* bats: show sqlite/mysql dump at the end
* removed "-v" (print package names) from "go build"
* general workflow cleanup
2022-06-17 16:12:49 +02:00
mmetc
10585bfecc
enabled linters and fixes for: misspell, predeclared, unconvert, ineffassign, gosimple, govet ( #1595 )
2022-06-16 14:41:54 +02:00
Thibault "bui" Koechlin
1c0fe09576
Add support for certificate authentication for agents and bouncers ( #1428 )
2022-06-08 16:05:52 +02:00
blotus
b7f1c5455f
do not rely on /proc/sys/kernel/random/uuid as fallback as it does not exists everywhere ( #1575 )
2022-06-06 18:20:10 +02:00
mmetc
799cc82bb5
functional tests, minor refactoring and lint/cleanup ( #1570 )
...
* cmd/crowdsec: removed log.Fatal()s, added tests and print error for unrecognized argument
* updated golangci-lint to v1.46
* lint/deadcode: fix existing issues
* tests: cscli config backup/restore
* tests: cscli completion powershell/fish
* err check: pflags MarkHidden()
* empty .dockerignore (and explain the reason)
* tests, errors.Wrap
* test for CS_LAPI_SECRET and minor refactoring
* minor style changes
* log cleanup
2022-06-06 15:24:48 +02:00
mmetc
df7c51f34e
fixed coverage reporting for functional tests; added cscli ( #1568 )
2022-05-31 10:01:30 +02:00
mmetc
1fc9587919
fix #1283 : update and enable error reports from golangci ( #1523 )
2022-05-25 22:27:50 +02:00
mmetc
1a293a2a27
cwhub: export SetHubBranch ( #1559 )
2022-05-24 15:46:48 +02:00
Thibault "bui" Koechlin
fe09737d80
Add support for machine heartbeat ( #1541 )
...
* add the last_heartbeat field
* add heartbeat controller
* add endpoint of heartbeat
* heartbeat integration
* add last_heartbeat to cscli machines list
2022-05-19 15:47:27 +02:00
mmetc
4b843d145a
cscli: avoid double output (error + log fatal) and automatic --help after each error ( #1536 )
2022-05-19 13:42:44 +02:00
mmetc
131ed1b0a7
error reporting ( #1501 )
...
* unified error reporting, removed redundancy, tests
2022-05-19 10:48:08 +02:00
mmetc
e6a2a7386c
changed option 'alerts-tainted' (which does not exist) to 'tainted' ( #1538 )
2022-05-19 09:55:49 +02:00
Manuel Sabban
18030e6c58
add notifications command ( #1537 )
...
* add notifications command
Co-authored-by: sabban <15465465+sabban@users.noreply.github.com>
2022-05-18 16:13:33 +02:00
Laurence Jones
6d6d82b3af
Memory check for cscli dashboard setup ( #1513 )
...
* Add 1gb recmem variable and use memory module
Since checking the RAM is not required to get the container up and running we can change this to a warn level
2022-05-18 11:05:01 +02:00
Laurence Jones
c2b298c93a
Add single quotes ( #1527 )
2022-05-17 16:57:04 +02:00
mmetc
b8547da4c3
"make localstack" target, link to docs/contributing ( #1522 )
2022-05-17 15:54:52 +02:00
blotus
0449ec1868
Windows Support ( #1159 )
2022-05-17 12:14:59 +02:00
blotus
8f111680bf
Allow to override statics in hubtest. ( #1495 )
2022-04-29 14:24:41 +02:00
Manuel Sabban
2e37d5ce97
update machineid lib ( #1489 )
...
* update machineid lib
Co-authored-by: sabban <15465465+sabban@users.noreply.github.com>
2022-04-28 12:18:16 +02:00
Greg Myers
0f4ab71f01
Fix typos in docs, comments, code ( #1483 )
2022-04-27 11:04:12 +02:00
AlteredCoder
8074a233e8
Fix typo in cscli metrics and debug message ( #1473 )
...
* Fix typo in cscli metrics and debug message
2022-04-22 11:29:55 +02:00
AlteredCoder
4273a0f243
cscli: add autocompletions for hubitems ( #1465 )
...
* Add autocompletion for hub items in cscli
2022-04-20 15:44:48 +02:00
he2ss
615895da9d
cscli: add force enroll feature ( #1430 )
...
* cscli: add force enroll feature
2022-04-20 13:34:17 +02:00
Shivam Sandbhor
8060f54f27
Cwhub testing ( #1438 )
...
* Add tests in cwhub and fix collection upgrade(#1431 )
Signed-off-by: Shivam Sandbhor <shivam.sandbhor@gmail.com
Co-authored-by: bui <thibault@crowdsec.net>
Co-authored-by: Thibault "bui" Koechlin <orixxx@gmail.com>
2022-04-19 12:07:35 +02:00
mmetc
4b9a0c4ef7
typos ( #1453 )
2022-04-19 11:25:27 +02:00
AlteredCoder
71165bcd30
Send all installed scenario to LAPI ( #1277 )
2022-04-13 17:48:29 +02:00
mmetc
5f2797c83c
more func test coverage; capture exit code for bincover ( #1425 )
2022-04-13 15:44:23 +02:00
mmetc
bf4bc0c9fc
single workflow for all tests, with bats coverage ( #1413 )
2022-04-05 11:00:11 +02:00
mmetc
1e63727064
int64 for metric units ( #1419 )
2022-04-04 21:50:19 +02:00
mmetc
dad22a6aba
instrument main() for tests ( #1399 )
2022-04-01 11:17:45 +02:00
mmetc
b202e387cf
fix "cscli" without arguments ( #1406 )
2022-03-31 16:50:38 +02:00
Thibault "bui" Koechlin
d8dc01cd94
Revamp unit tests ( #1368 )
...
* Revamp unit tests
* Increase coverage
* Use go-acc to get cross packages coverage
Signed-off-by: Shivam Sandbhor <shivam.sandbhor@gmail.com>
2022-03-29 14:20:26 +02:00
mmetc
caf1dc71fb
allow capi register in functional tests ( #1384 )
2022-03-24 11:07:54 +01:00
AlteredCoder
411baa4dcf
Improve cscli metrics units ( #1374 )
...
* Improve cscli metrics units
2022-03-21 12:13:36 +01:00
AlteredCoder
e4cc5fc997
Add -m flag for decisions list to display the machine ( #1361 )
...
* Add -m flag for decisions list to display the machine
2022-03-16 17:29:31 +01:00
Shivam Sandbhor
023ac9e138
Add trusted IPs which have admin API access ( #1352 )
...
* Add trusted IPs which have admin API access
2022-03-16 17:28:34 +01:00
AlteredCoder
b57eb92bbc
Allow to ignore errors when installing multiple configuration items ( #1359 )
...
* Allow to ignore errors when installing multiple configuration items
2022-03-16 17:27:30 +01:00
AlteredCoder
24797c1534
Allow cscli remove to remove with --all ( #1360 )
2022-03-16 17:26:31 +01:00
AlteredCoder
0dd37240a5
Display acquisition dir in cscli config show ( #1349 )
2022-03-14 18:28:31 +01:00
mmetc
b6aca81ebd
allow "cscli completion..." without configuration file ( #1340 )
2022-03-10 14:57:14 +01:00
mmetc
aca37a38e7
return 1 with incomplete command line; always check error when calling cmd.Help ( #1335 )
2022-03-10 13:55:25 +01:00
Thibault "bui" Koechlin
52132ce398
fix #1157 ( #1327 )
2022-03-10 13:23:21 +01:00
mmetc
7c0593c659
noop code removal, typos and lint fixes ( #1329 )
2022-03-09 16:15:18 +01:00
Shivam Sandbhor
0f5e922851
Warn when log file in explain command is large. ( #1293 )
...
* Warn when log file in explain command is large.
Signed-off-by: Shivam Sandbhor <shivam.sandbhor@gmail.com>
2022-02-28 14:57:59 +01:00