- /usr/lib/systemd/system/unicorn.service
[Unit] Description=Unicorn Server After=mysqld.service [Service] User=adachin WorkingDirectory=/var/www/app Environment=RAILS_ENV=production SyslogIdentifier=unicorn PIDFile=/var/www/app/tmp/pids/unicorn.pid ExecStart=/home/adachin/.rbenv/shims/bundle exec unicorn_rails -c /var/www/app/config/unicorn.conf.rb ExecStop=/usr/bin/kill -QUIT $MAINPID ExecReload=/bin/kill -USR2 $MAINPID [Install] WantedBy=multi-user.target
- systemctl
# chmod +x /etc/systemd/system/unicorn.service # systemctl daemon-reload # systemctl enable unicorn # systemctl start unicorn # systemctl stop unicorn # systemctl restart unicorn
Was this helpful?
0 / 0
1989年生まれのLancers SRE。 ホスティングから大規模なアドテクなどのインフラエンジニアとして携わり、AnsibleやTerraformでのインフラコード化を推進。副業では数社サーバー保守なども実施している。また、「脆弱性スキャナVuls」のOSS活動もしており、自称エバンジェリスト/技術広報/テクニカルサポート/コントリビュータでもある。現在はサービスの信頼性向上、可用性、レイテンシ、パフォーマンス、モニタリング、緊急対応、インフラコード化、リファクタリング、セキュリティ強化、新技術の検証、Docker開発環境の提供、AWSでのインフラ構築、グループ会社のインフラをECS/Fargateへ移行、CakePHP4での管理画面作成、メンター、分析基盤の運用を担当している。