Commit Graph

48 Commits

Author SHA1 Message Date
Nathan Baulch 4f23049374
Fix minor typos (#11935) 2024-09-06 15:59:43 +01:00
Carlos Tadeu Panato Junior 12fbe9b163
golangci-lint update, ci cleanup, group dependabot updates (#11071)
* bump golangci-lint to v1.56.x

Signed-off-by: cpanato <ctadeu@gmail.com>

* cleanup empty lines

Signed-off-by: cpanato <ctadeu@gmail.com>

* group dependabot updates

Signed-off-by: cpanato <ctadeu@gmail.com>

* run on job changes as well

Signed-off-by: cpanato <ctadeu@gmail.com>

* remove deprecated checks

Signed-off-by: cpanato <ctadeu@gmail.com>

* fix lints and format

Signed-off-by: cpanato <ctadeu@gmail.com>

---------

Signed-off-by: cpanato <ctadeu@gmail.com>
2024-03-07 02:39:53 -08:00
Ricardo Katz cf889c6c47
Disable user snippets per default (#10393)
* Disable user snippets per default

* Enable snippet on tests
2023-09-10 20:02:10 -07:00
Chen Chen b3060bfbd0
Fix golangci-lint errors (#10196)
* Fix golangci-lint errors

Signed-off-by: z1cheng <imchench@gmail.com>

* Fix dupl errors

Signed-off-by: z1cheng <imchench@gmail.com>

* Fix comments

Signed-off-by: z1cheng <imchench@gmail.com>

* Fix errcheck lint errors

Signed-off-by: z1cheng <imchench@gmail.com>

* Fix assert in e2e test

Signed-off-by: z1cheng <imchench@gmail.com>

* Not interrupt the waitForPodsReady

Signed-off-by: z1cheng <imchench@gmail.com>

* Replace string with constant

Signed-off-by: z1cheng <imchench@gmail.com>

* Fix comments

Signed-off-by: z1cheng <imchench@gmail.com>

* Revert write file permision

Signed-off-by: z1cheng <imchench@gmail.com>

---------

Signed-off-by: z1cheng <imchench@gmail.com>
2023-08-31 00:36:48 -07:00
Chen Chen d44a8e0045
Fix golang-ci linter errors (#10128)
* Fix golang-ci linter errors

Signed-off-by: z1cheng <imchench@gmail.com>

* Fix gofmt errors

Signed-off-by: z1cheng <imchench@gmail.com>

* Add nolint comment to defaults.Backend in Configuration

Signed-off-by: z1cheng <imchench@gmail.com>

* Add #nosec comment to rand.New func

Signed-off-by: z1cheng <imchench@gmail.com>

* Fix errcheck warnings

Signed-off-by: z1cheng <imchench@gmail.com>

* Fix gofmt check

Signed-off-by: z1cheng <imchench@gmail.com>

* Fix unit tests and comments

Signed-off-by: z1cheng <imchench@gmail.com>

---------

Signed-off-by: z1cheng <imchench@gmail.com>
2023-07-03 05:50:52 -07:00
guangwu 114ae77fb7
chore: pkg imported more than once (#10048) 2023-06-11 11:49:47 -07:00
Eng Zer Jun d02ba28b96
perf: avoid unnecessary byte/string conversion (#10012)
We can use alternative functions to avoid unnecessary byte/string
conversion calls and reduce allocations.

Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
2023-06-01 07:29:47 -07:00
Ricardo Katz c86d50ecef
Move APIs to be used by both controller and configurer (#8854) 2022-07-21 17:32:48 -07:00
Ricardo Pchevuzinske Katz 7304086202 Move util to specific package location 2022-07-21 18:06:55 -03:00
Ricardo Katz 4c6a7ee158
Decouple shared functions between controllers (#8829)
* Decouple shared functions between controllers

* Apply suggestions from code review

Co-authored-by: Jintao Zhang <tao12345666333@163.com>

* Fix package names and fmt

Co-authored-by: Jintao Zhang <tao12345666333@163.com>
2022-07-20 11:53:44 -07:00
Eugene Apollonsky af745bd97d
use listen to ensure the port is free (#6990) (#7467)
Co-authored-by: boxjan <i@boxjan.li>
2021-08-09 05:31:31 -07:00
Ricardo Katz d226d831bd Update go version, modules and remove ioutil 2021-08-06 14:15:21 -03:00
Elvin Efendi 2cff9fa41d generalize cidr parsing and improve lua tests 2021-01-04 15:01:55 -05:00
Josh Soref a8728f3d2c Spelling 2020-12-15 16:10:48 -05:00
Manuel Alejandro de Brito Fontes d781d99797 Fixes for gosec 2020-12-04 20:29:07 -03:00
Manuel Alejandro de Brito Fontes 108637bb1c Migrate to structured logging (klog) 2020-09-27 18:59:57 -03:00
Manuel Alejandro de Brito Fontes cb86c5698c Migrate to klog v2 2020-08-08 21:01:03 -04:00
Manuel Alejandro de Brito Fontes 55820ef1e8
Allow multiple CA Certificates (#4556) 2019-09-13 09:22:24 -03:00
Ricardo Katz 9c51676f17 Add support to CRL (#3164)
Signed-off-by: Ricardo Pchevuzinske Katz <ricardo.katz@serpro.gov.br>

Add support to CRL

Signed-off-by: Ricardo Pchevuzinske Katz <ricardo.katz@serpro.gov.br>
2019-09-03 16:47:28 -04:00
Manuel Alejandro de Brito Fontes 8def5ef7ca
Add support for multiple alias and remove duplication of SSL certificates (#4472) 2019-08-26 10:58:44 -04:00
Manuel Alejandro de Brito Fontes 23ed3ba4c4
Fix file permissions to support volumes 2019-08-15 20:48:37 -04:00
Manuel Alejandro de Brito Fontes 80bd481abb
Only support SSL dynamic mode 2019-08-13 17:33:34 -04:00
Manuel Alejandro de Brito Fontes 3d7a09347d
Apply fixes suggested by staticcheck 2019-07-08 16:18:52 -04:00
Manuel Alejandro de Brito Fontes 8807db9748
Check and complete intermediate SSL certificates 2019-07-04 19:13:21 -04:00
Manuel Alejandro de Brito Fontes 14a394fc9e
Update nginx (#4150)
* Update nginx image
* Fix IPV6 test issues in Prow
2019-06-04 12:15:03 -04:00
Thibault Jamet 1cd17cd12c
Implement a validation webhook
In case some ingress have a syntax error in the snippet configuration,
the freshly generated configuration will not be reloaded to prevent tearing down existing rules.
Although, once inserted, this configuration is preventing from any other valid configuration to be inserted as it remains in the ingresses of the cluster.
To solve this problem, implement an optional validation webhook that simulates the addition of the ingress to be added together with the rest of ingresses.
In case the generated configuration is not validated by nginx, deny the insertion of the ingress.

In case certificates are mounted using kubernetes secrets, when those
changes, keys are automatically updated in the container volume, and the
controller reloads it using the filewatcher.

Related changes:

- Update vendors
- Extract useful functions to check configuration with an additional ingress
- Update documentation for validating webhook
- Add validating webhook examples
- Add a metric for each syntax check success and errors
- Add more certificate generation examples
2019-04-18 19:07:04 +02:00
Elvin Efendi 13a7e2c5d0 refactor GetFakeSSLCert 2019-04-14 09:35:48 -04:00
Manuel Alejandro de Brito Fontes 14a9e9f3fa
Update dependencies client-go to release-11.0 and kubernetes-1.14.0 2019-03-28 20:43:18 -03:00
Elvin Efendi c934509309 fix function comment 2019-03-11 00:53:06 -04:00
Elvin Efendi c28247abf6 adjust unit tests 2019-03-11 00:53:06 -04:00
Elvin Efendi 70df5e03e5 clean up certificate processing 2019-03-11 00:53:06 -04:00
Elvin Efendi 0dc5a1d2e2 do not repeat cert verification against root ca 2019-03-11 00:53:06 -04:00
Elvin Efendi 301a4fb9a5 extract common logic into a helper 2019-03-11 00:53:06 -04:00
Manuel Alejandro de Brito Fontes a3bcbeb3d2
Add support for redirect https to https when from-to-www-redirect is defined 2019-01-10 20:59:49 -03:00
Zhenhai Gao 05d2baede6 Fix log output format
Signed-off-by: Zhenhai Gao <gaozh1988@live.com>
2018-12-06 09:59:31 +08:00
Manuel Alejandro de Brito Fontes 68f344233b Fix lint issues 2018-12-05 13:28:28 -03:00
Manuel Alejandro de Brito Fontes 2fa55eabf6 Replace glog with klog 2018-12-05 13:27:55 -03:00
mikeweiwei b85f1fa551 Fix typos 2018-11-08 17:04:46 +08:00
Henry Tran 7faf089082 Add dynamic certificate feature to controller 2018-08-16 20:19:33 -04:00
Manuel de Brito Fontes 123ffc0c38
Fix IPV6 detection 2018-08-06 13:05:32 -04:00
Manuel de Brito Fontes b148f113ae
Use authbind to bind privileged ports 2018-08-05 11:18:50 -04:00
Manuel de Brito Fontes 1542a12764
Refactor controller metrics interface 2018-07-12 12:46:34 -04:00
Manuel de Brito Fontes 7ded31d7a8
Create file permission constants 2018-06-12 11:06:14 -04:00
Oilbeater 17f6996941 fix nil pointer when ssl with ca.crt (#2331) 2018-04-11 09:30:16 -03:00
Lihua Tang 1947f35121 Fix typos (#2046) 2018-02-07 19:15:50 -08:00
Manuel de Brito Fontes e9a00ff916 Refactoring of kubernetes informers and local caches 2018-01-18 16:14:54 -03:00
Manuel de Brito Fontes ff9e804d9a Refactor SSL intermediate CA certificate check 2017-11-13 12:07:14 -03:00
Manuel de Brito Fontes 73fe95722c Rename package pkg to internal 2017-11-11 14:53:44 -03:00