[Unit]
Description=Metin game runtime (%i)
After=metin-auth.service metin-db-ready.service
Wants=metin-auth.service metin-db-ready.service
Requires=metin-auth.service metin-db-ready.service
PartOf=metin-server.service
Before=metin-server.service

[Service]
Type=simple
User={{USER_NAME}}
Group={{GROUP_NAME}}
EnvironmentFile=-{{ENV_FILE}}
WorkingDirectory={{RUNTIME_ROOT}}
ExecStart=/usr/local/libexec/metin-game-instance-start %i
Restart=on-failure
RestartSec=5
KillSignal=SIGTERM
TimeoutStopSec=60
LimitNOFILE=65535

[Install]
RequiredBy=metin-server.service
