Skip to content

Instantly share code, notes, and snippets.

@garystafford
Created September 21, 2018 16:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save garystafford/b1e2d1edeb621f9f96e0bc5946800928 to your computer and use it in GitHub Desktop.
Save garystafford/b1e2d1edeb621f9f96e0bc5946800928 to your computer and use it in GitHub Desktop.
SOURCE_IP=<gke_cluster_public_ip_address>
PORT=9300
gcloud compute \
--project=wp-search-bot \
firewall-rules create elk-1-tcp-${PORT} \
--description=elk-1-tcp-${PORT} \
--direction=INGRESS \
--priority=1000 \
--network=default \
--action=ALLOW \
--rules=tcp:${PORT} \
--source-ranges=${SOURCE_IP} \
--target-tags=elk-1-tcp-${PORT}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment