diff --git a/cmd/flux/bootstrap_git.go b/cmd/flux/bootstrap_git.go
index 2f4c49d15267c52ad69197ccd2c70191e95fb4d7..2d5f381fd22338e35bfb3e3bc6f223b539f3f1c9 100644
--- a/cmd/flux/bootstrap_git.go
+++ b/cmd/flux/bootstrap_git.go
@@ -173,6 +173,9 @@ func bootstrapGitCmdRun(cmd *cobra.Command, args []string) error {
 		if bootstrapArgs.sshHostname != "" {
 			repositoryURL.Host = bootstrapArgs.sshHostname
 		}
+		if bootstrapArgs.privateKeyFile != "" {
+			secretOpts.PrivateKeyPath = bootstrapArgs.privateKeyFile
+		}
 
 		// Configure last as it depends on the config above.
 		secretOpts.SSHHostname = repositoryURL.Host