diff --git a/.github/workflows/control-instance.yml b/.github/workflows/control-instance.yml index eec2e996..df9ae877 100644 --- a/.github/workflows/control-instance.yml +++ b/.github/workflows/control-instance.yml @@ -20,6 +20,18 @@ jobs: env: NUMBER: ${{ github.event.issue.number }} + - name: Send mail + uses: dawidd6/action-send-mail@2cea9617b09d79a095af21254fbcb7ae95903dde # v3.12.0 + with: + server_address: smtp.gmail.com + server_port: 465 + secure: true + username: ${{secrets.MAIL_USERNAME}} + password: ${{secrets.MAIL_PASSWORD}} + from: MorphoCloudPortal + subject: "[MorphoCloudPortal] Instance ${{ github.event.issue.number }} started" + body: Instance ${{ github.event.issue.number }} started + stop: runs-on: self-hosted if: @@ -30,3 +42,15 @@ jobs: echo Stopping instance associated with issue $NUMBER env: NUMBER: ${{ github.event.issue.number }} + + - name: Send mail + uses: dawidd6/action-send-mail@2cea9617b09d79a095af21254fbcb7ae95903dde # v3.12.0 + with: + server_address: smtp.gmail.com + server_port: 465 + secure: true + username: ${{secrets.MAIL_USERNAME}} + password: ${{secrets.MAIL_PASSWORD}} + from: MorphoCloudPortal + subject: "[MorphoCloudPortal] Instance ${{ github.event.issue.number }} stopped" + body: Instance ${{ github.event.issue.number }} stopped diff --git a/.github/workflows/create-instance.yml b/.github/workflows/create-instance.yml index 65cf5939..8690e67d 100644 --- a/.github/workflows/create-instance.yml +++ b/.github/workflows/create-instance.yml @@ -17,3 +17,15 @@ jobs: echo Creating instance associated with issue $NUMBER env: NUMBER: ${{ github.event.issue.number }} + + - name: Send mail + uses: dawidd6/action-send-mail@2cea9617b09d79a095af21254fbcb7ae95903dde # v3.12.0 + with: + server_address: smtp.gmail.com + server_port: 465 + secure: true + username: ${{secrets.MAIL_USERNAME}} + password: ${{secrets.MAIL_PASSWORD}} + from: MorphoCloudPortal + subject: "[MorphoCloudPortal] Instance ${{ github.event.issue.number }} created" + body: Instance ${{ github.event.issue.number }} created