How to Disable Webhook and Service Requests to Local Network When Using GitLab?
To facilitate the use of code repository triggers, the platform allows Webhook and service requests to the local network by default when integrating with GitLab. However, due to the specificity of Webhook usage , if you do not need to configure code repository triggers or need to meet stricter security requirements, you can disable Webhook and service requests to the local network.
Caution: After disabling, code repository triggers cannot be used.
Procedure
Please complete the following operations on both the platform side and the GitLab side.
Platform side
-
Switch to the global cluster.
-
In the left navigation bar, click Clusters > Resources.
-
Search for the ConfigMap resource object.
-
Find the ConfigMap named katanomi-config.
Note: The ConfigMap is in the same namespace as the katamoni instance.
-
Click
> Update. -
Add the following configuration to disable Webhook and service requests to the local network.
apiVersion: v1 data: plugin.gitlab.allow-local-requests: "false" #Prohibition Webhook Requests from Services to Local Network kind: ConfigMap -
Click Update.
GitLab Side
-
Log in to GitLab with an administrator account.
-
In the top navigation bar, click
. -
In the left navigation bar, click Settings > Networking.
-
In the Outbound requests section, uncheck the option Allow requests to the local network from web hooks and services.