Commit 3daae85b authored by Pedro Eduardo Trujillo's avatar Pedro Eduardo Trujillo
Browse files

Merge branch 'dev' into 'master'

Ajusta parámetros, CI y versión de plugin

See merge request redmic-project/log/fluentd!6
parents 9594e368 e389150b
Loading
Loading
Loading
Loading
+5 −17
Original line number Diff line number Diff line
@@ -6,7 +6,7 @@ stages:
variables:
  DOCKER_DRIVER: overlay2
  FLUENTD_VERSION: '1.3'
  ES_PLUGIN_VERSION: '2.12.1'
  ES_PLUGIN_VERSION: '3.4.0'
  STACK: log
  SERVICES_TO_CHECK: log_${CI_PROJECT_NAME}
  IMAGE_NAME: ${CI_REGISTRY_IMAGE}
@@ -76,12 +76,9 @@ container-scanning:

deploy-supporting-branch-develop:
  stage: deploy
  image: registry.gitlab.com/redmic-project/docker/docker-deploy:latest
  image: ${DOCKER_DEPLOY_IMAGE_NAME}:${DOCKER_DEPLOY_IMAGE_TAG}
  variables:
    SSH_REMOTE: ${DEV_SSH_REMOTE}
    ES_HOSTS: ${DEV_ES_HOSTS}
    ES_USER: ${DEV_ES_USER}
    ES_PASS: ${DEV_ES_PASS}
  script:
    - >
      deploy.sh IMAGE_NAME=${IMAGE_NAME} IMAGE_TAG=${IMAGE_TAG} ES_HOSTS=${ES_HOSTS} ES_USER=${ES_USER}
@@ -96,12 +93,9 @@ deploy-supporting-branch-develop:

deploy-stable-branch-develop:
  stage: deploy
  image: registry.gitlab.com/redmic-project/docker/docker-deploy:latest
  image: ${DOCKER_DEPLOY_IMAGE_NAME}:${DOCKER_DEPLOY_IMAGE_TAG}
  variables:
    SSH_REMOTE: ${DEV_SSH_REMOTE}
    ES_HOSTS: ${DEV_ES_HOSTS}
    ES_USER: ${DEV_ES_USER}
    ES_PASS: ${DEV_ES_PASS}
  script:
    - >
      deploy.sh IMAGE_NAME=${IMAGE_NAME} IMAGE_TAG=${IMAGE_TAG} ES_HOSTS=${ES_HOSTS} ES_USER=${ES_USER}
@@ -114,12 +108,9 @@ deploy-stable-branch-develop:

deploy-supporting-branch-production:
  stage: deploy
  image: registry.gitlab.com/redmic-project/docker/docker-deploy:latest
  image: ${DOCKER_DEPLOY_IMAGE_NAME}:${DOCKER_DEPLOY_IMAGE_TAG}
  variables:
    SSH_REMOTE: ${PRO_SSH_REMOTE}
    ES_HOSTS: ${PRO_ES_HOSTS}
    ES_USER: ${PRO_ES_USER}
    ES_PASS: ${PRO_ES_PASS}
  script:
    - >
      deploy.sh IMAGE_NAME=${IMAGE_NAME} IMAGE_TAG=${IMAGE_TAG} ES_HOSTS=${ES_HOSTS} ES_USER=${ES_USER}
@@ -134,12 +125,9 @@ deploy-supporting-branch-production:

deploy-stable-branch-production:
  stage: deploy
  image: registry.gitlab.com/redmic-project/docker/docker-deploy:latest
  image: ${DOCKER_DEPLOY_IMAGE_NAME}:${DOCKER_DEPLOY_IMAGE_TAG}
  variables:
    SSH_REMOTE: ${PRO_SSH_REMOTE}
    ES_HOSTS: ${PRO_ES_HOSTS}
    ES_USER: ${PRO_ES_USER}
    ES_PASS: ${PRO_ES_PASS}
  script:
    - >
      deploy.sh IMAGE_NAME=${IMAGE_NAME} IMAGE_TAG=${IMAGE_TAG} ES_HOSTS=${ES_HOSTS} ES_USER=${ES_USER}
+1 −1
Original line number Diff line number Diff line
@@ -4,7 +4,7 @@ FROM fluent/fluentd:v${FLUENTD_VERSION}

LABEL maintainer="info@redmic.es"

ARG ES_PLUGIN_VERSION=2.12.1
ARG ES_PLUGIN_VERSION=3.4.0

RUN apk add --update --no-cache --virtual .build-deps \
		build-base \
+1 −1
Original line number Diff line number Diff line
ES_HOSTS=es-1:9200,es-2:9200
ES_HOSTS=es-1:9200,es-2:9200,es-3:9200
ES_USER=user
ES_PASS=pass
+9 −2
Original line number Diff line number Diff line
@@ -9,16 +9,23 @@
	</record>
</filter>

<filter **>
	@type elasticsearch_genid
	hash_id_key _hash
</filter>

<match **>
	@type elasticsearch_dynamic
	@id elasticsearch-output
	@log_level debug
	id_key _hash
	remove_keys _hash
	hosts "#{ENV['ES_HOSTS']}"
	user "#{ENV['ES_USER']}"
	password "#{ENV['ES_PASS']}"
	type_name fluentd
	logstash_format true
	logstash_prefix fluentd-${tag_parts[0]}
	logstash_dateformat %Y%m%d
	flush_interval 5s
	logstash_dateformat %Y%m
	flush_interval 30s
</match>
+1 −0
Original line number Diff line number Diff line
@@ -26,6 +26,7 @@ services:
          cpus: '1'
          memory: 128M
        reservations:
          cpus: '0.1'
          memory: 64M

networks: