2월, 2022의 게시물 표시

[Eureka] Django Eureka 연동

 [Eureka Client 설치] pip install py_eureka_client [Django App 설정] app/__init__.py import py_eureka_client.eureka_client as eureka_client import py_eureka_client.logger as logger your_rest_server_port = 8001 # The flowing code will register your server to eureka server and also start to send heartbeat every 30 seconds discovery_client = eureka_client .init( eureka_server = "http://localhost:8761" , app_name = "tricycle" , instance_host = "localhost" , instance_port = your_rest_server_port , ha_strategy = eureka_client .HA_STRATEGY_STICK) logger .set_level( "DEBUG" )

[windows] filebeat 스케쥴링 테스트

 [windows server 2021 설치] aws에 windows server 2021 Basic 설치 rdp로 접속 (키 필요) [windows server 2021 ftp 설치] iis설치 ftp Enable (windows 방화벽 자동 설정) 참조사이트 : http://blog.servis.co.kr/index.php/2019/10/08/windows-server-2012-ftp/ [windows server 2021 task scheduler 설치] task scheduler 실행 create basic task 실행 Create a Basic Type : name 입력 - next Trigger : 주기 선택 - next Action : Start a program 선택 - next Start a Program :     - Program/script : 실행파일명만 입력    - Start in (optional) : 실행파일이 있는 Full Path 입력 [batch] cd C:\elastic\filebeat-7.9.2-windows-x86_64 rmdir /s /q data timeout /t 5 .\filebeat run --once -c filebeat.yml [logstash] input {   beats {     # host => "1.234.25.136"     port => 30001   } } output {   elasticsearch {     hosts => ["http://192.168.0.136:49100"]     index => "ra_program-%{+YYYY.MM.dd}"     user => "elastic"     password => "nadaimma"     # ssl => true     # ssl_certificate_verification => false     # c