Reindexing with Logstash can be done with the following Logstash configuration:
input {
# We read from the "old" index
elasticsearch {
hosts => ["http://<host>:<port>"]
index => "<old_index>"
size => 500
scroll => "5m"| # Initialize the scroll | |
| page = es.search( | |
| index = 'yourIndex', | |
| doc_type = 'yourType', | |
| scroll = '2m', | |
| search_type = 'scan', | |
| size = 1000, | |
| body = { | |
| # Your query's body | |
| }) |
| n_shards=$1 | |
| echo "ES version" | |
| curl -s localhost:9200 | |
| echo "Create index" | |
| curl -si -H 'Content-type: application/json' -X PUT localhost:9200/twitter -d ' | |
| { | |
| "settings": { | |
| "index": { |
| input { | |
| elasticsearch { | |
| hosts => [ "HOSTNAME_HERE" ] | |
| port => "9200" | |
| index => "INDEXNAME_HERE" | |
| size => 1000 | |
| scroll => "5m" | |
| docinfo => true | |
| scan => true | |
| } |
Reindexing with Logstash can be done with the following Logstash configuration:
input {
# We read from the "old" index
elasticsearch {
hosts => ["http://<host>:<port>"]
index => "<old_index>"
size => 500
scroll => "5m"| FROM mirror-hub.docker.tech.lastmile.com/alpine:3.5 | |
| RUN apk add --no-cache curl jq | |
| RUN curl -o /usr/local/bin/kubectl https://storage.googleapis.com/kubernetes-release/release/v1.5.3/bin/linux/amd64/kubectl && chmod +x /usr/local/bin/kubectl | |
| COPY rmpeers / | |
| CMD ["/rmpeers"] |
| #!/bin/bash -e | |
| # Setup a Root CA in vault | |
| # Generate and sign an Intermediate cert | |
| # | |
| # Requires: | |
| # * A running vault server already initialzed and unsealed | |
| # * Environment variable VAULT_TOKEN is set | |
| # * vault cli (https://www.vaultproject.io) | |
| # * httpie (https://github.com/jkbrzt/httpie) |
I hereby claim:
To claim this, I am signing this object:
| #!/usr/bin/env python | |
| """ | |
| Logging part of a multicast group scanner. | |
| Needs to be run with capabilities allowing it to read | |
| raw data from the network interface. (usually root) | |
| Author: Lasse Karstensen <lasse.karstensen@gmail.com>, April 2013. | |
| """ | |
| import sys |
| #!/usr/bin/python | |
| """ | |
| Multicast group scanner. | |
| Author: Lasse Karstensen <lasse.karstensen@gmail.com>, November 2014 | |
| """ | |
| import gevent | |
| from gevent import monkey | |
| monkey.patch_all() |
| # | |
| # Customized VCL file for serving up a Drupal site with multiple back-ends. | |
| # | |
| # For more information on this VCL, visit the Lullabot article: | |
| # http://www.lullabot.com/articles/varnish-multiple-web-servers-drupal | |
| # | |
| # Define the internal network subnet. | |
| # These are used below to allow internal access to certain files while not | |
| # allowing access from the public internet. |