diff --git a/.editorconfig b/.editorconfig
index 28f1abd3add1..ff5c1b2d414d 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -5,6 +5,7 @@ root = true
 charset = utf-8
 insert_final_newline = true
 trim_trailing_whitespace = true
+end_of_line = lf
 
 [*.go]
 indent_style = tab
diff --git a/.gitattributes b/.gitattributes
index 56abc3c2bd95..d71939950d67 100644
--- a/.gitattributes
+++ b/.gitattributes
@@ -1,6 +1,7 @@
+* text=auto eol=lf
 conf/* linguist-vendored
 docker/* linguist-vendored
 options/* linguist-vendored
 public/* linguist-vendored
 scripts/* linguist-vendored
-templates/* linguist-vendored
\ No newline at end of file
+templates/* linguist-vendored