D:\nginx-1.12.2 에 설치되어 있을때 아래와 같이 배치파일을 만들어서 실행하면 된다.
시작 배치 파일 (nginx_start.bat) |
@ECHO OFF |
종료 배치 파일 (nginx_stop.bat) |
@ECHO OFF |
nginx.exe -s stop 으로 종료가 되지 않을 경우 tasskill 명령을 이용해서 강제 종료한다.
taskkill /f /im nginx.exe
실행할때 인자(args)를 받아서 처리하려면 아래와 같이 만들어준다.
배치 파일 (nginx.bat) |
:Init
:Condition
:Start
:Stop
:Reload
:Kill
:Error
:End |
실행하려면 배치파일이 있는 곳으로 이동(chdir)해서 아래와 같이 실행하면 된다.
nginx.bat start
nginx.bat stop
nginx.bat restart
nginx.bat reload
...
댓글 0
- 전체
- Android+iPhone+etc.
- Apache+Tomcat
- ASP
- ASP.NET
- DataBase
- HTML / CSS
- JavaScript
- JSP
- Linux Server
- PHP
- Raspberry pi
- Windows Server
- WIPI
- Etc.