• 使用を開始する
  • 関連ドキュメント

End of sales and support for Opsgenie

Atlassian will discontinue new sales of Opsgenie on June 4, 2025 and end support for Opsgenie on April 5, 2027. Read the full announcement and learn about next-generation incident response options via Jira Service Management and Compass.

Opsgenie Edge Connector の実行

Linux の場合

  • 次のコマンドは、OEC を起動、停止、再起動します。

シェル

sudo systemctl start oec sudo systemctl stop oec sudo systemctl restart oec
  • 環境変数を使用した使用例:

シェル

sudo systemctl set-environment OEC_CONF_SOURCE_TYPE=git sudo systemctl set-environment OEC_CONF_GIT_URL=git@gitlab.com:metehan2/test-private-conf.git sudo systemctl set-environment OEC_CONF_GIT_PRIVATE_KEY_FILEPATH=~/.ssh/id_rsa sudo systemctl set-environment OEC_CONF_GIT_FILEPATH=~/oec/config.json sudo systemctl start oec

または

シェル

sudo systemctl set-environment OEC_CONF_SOURCE_TYPE=local sudo systemctl set-environment OEC_CONF_LOCAL_FILEPATH=~/opsgenie/oec/config.json sudo systemctl start oec

 

古い RHEL ベースのディストリビューション (6.x.x 以前)

シェル

sudo service oec start sudo service oec stop sudo service oec restart # Environment variables can be put in bash configuration files

 

Windows の場合

SIGINT および SIGTERM 信号は OEC を停止するために使用されます。OEC をサービスとして使用している間は、Windows のネイティブメソッドを使用して OEC を停止/再起動できません。OECをサービスとして実行するためのヘルパー実行可能ファイルが提供されます。

  • 環境変数 (Env) と引数 (Args) は、oecService<32|64>.json を介して次のように設定できます。

JSON

{ "Name": "OEC Service", "DisplayName": "OEC Service", "Description": "Run the OEC Service", "OECPath" : "C:\\Users\\Administrator\\Desktop\\OpsgenieEdgeConnector<32|64>.exe", "Args" : ["-oec-metrics", "7070"], "Env": [ "OEC_CONF_LOCAL_FILEPATH=C:\\Users\\Administrator\\Desktop\\config.json", "OEC_CONF_SOURCE_TYPE=local" ], "Stderr": "C:\\Users\\Administrator\\Desktop\\oecErr.log", "Stdout": "C:\\Users\\Administrator\\Desktop\\oecOut.log" }
  • 次のコマンドは、OEC amd64 バージョンを起動、停止、再起動します。

シェル

oecService64.exe start oecService64.exe stop oecService64.exe restart
  • 次のコマンドは、OEC 386 バージョンを起動、停止、再起動します。

シェル

oecService32.exe start oecService32.exe stop oecService32.exe restart

 

Docker での OEC の実行

  1. git clone https://github.com/opsgenie/OEC.git を使用してリポジトリのクローンを作成します

  2. docker build . -t oec を実行します

  3. OEC は実行に構成ファイルを使用するので、コンテナーからファイルにアクセスできるように、Docker コンテナーにボリュームを提供する必要があります。また、上記の環境変数をコンテナーに提供する必要があります。Docker コンテナーを実行するコマンドの例を次に示します。

シェル

docker run -ti \ -v /Users/foo/Documents/bar:/home/opsgenie \ -e OEC_CONF_SOURCE_TYPE="local" \ -e OEC_CONF_LOCAL_FILEPATH="/home/opsgenie/OEC.yaml" \ OEC

上記のコマンドは、2つの環境変数を使用してコンテナーを実行し、ホストマシンの "bar" フォルダと、コンテナー内の "opsgenie" フォルダとの間にボリュームを作成します。

OEC を実行するために Docker コンテナーを使用しているので、ホストマシンではなく、コンテナーに従ってファイルパスを指定する必要があります。

リポジトリの構成を使用する場合は、ボリュームを使用して ssh_known_hosts ファイルをイメージに追加する必要があります。また、イメージ内の ssh_know_hosts ファイルパスに、SSH_KNOWN_HOSTS 環境変数を設定する必要がある場合もあります。リポジトリの構成ファイルを使用して OEC を実行するコマンドの例を以下に示します。このコマンドは、ホスト・マシンからログ・ファイルにアクセスするための追加のボリュームも作成します。

シェル

docker run -ti \ -v /Users/erenkizilay/Documents/dummyDir:/home/opsgenie \ -v /Users/erenkizilay/Documents/dummyDir:/var/log/opsgenie \ -v /Users/erenkizilay/.ssh/known_hosts:/etc/ssh/ssh_known_hosts \ -e OEC_CONF_SOURCE_TYPE="git" -e OEC_CONF_GIT_FILEPATH=/config.json \ -e OEC_CONF_GIT_PRIVATE_KEY_FILEPATH=/var/log/opsgenie/id_rsa \ -e OEC_CONF_GIT_URL=git@gitlab.com:erenkizilay/OEC-conf.git \ -e SSH_KNOWN_HOSTS=/etc/ssh/ssh_known_hosts \ OEC



さらにヘルプが必要ですか?

アトラシアン コミュニティをご利用ください。