build fail email message with raised error message - lack commit url - lack pubkey - repo url for the commit url not in upstream - commit not exist or not available - no more available account on jumper server
Signed-off-by: Luan Shengde shdluan@163.com --- lib/assign-account-fail-eamil.rb | 38 ++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100755 lib/assign-account-fail-eamil.rb
diff --git a/lib/assign-account-fail-eamil.rb b/lib/assign-account-fail-eamil.rb new file mode 100755 index 0000000..1c2133c --- /dev/null +++ b/lib/assign-account-fail-eamil.rb @@ -0,0 +1,38 @@ +#!/usr/bin/env ruby +# SPDX-License-Identifier: MulanPSL-2.0+ +# Copyright (c) 2020 Huawei Technologies Co., Ltd. All rights reserved. +# frozen_string_literal: true + +def build_apply_account_fail_email(my_info, message) + email_msg = <<~EMAIL_MESSAGE + To: #{my_info['my_email']} + Subject: [compass-ci] apply account failed + + Dear user: + + Your application for account failed with following error: + + #{message} + + In order to successfully apply an account, please pay attention to the following points: + + 1. mail subject + the subject should exactly: apply account + + 2. commit url + when you writing the url, add prefix: my oss commit + example: + my oss commit: https://github.com/torvalds/aalinux/commit/7be74942f184fdfba34ddd19a0d995deb... + + attention: + ensure you commit url exist and available to access. + + 3. ssh pubkey + you need to add a pubkey as an attachment with name 'id_rsa.pub' to the email. + + regards + compass-ci + EMAIL_MESSAGE + + return email_msg +end
On Thu, Nov 12, 2020 at 07:26:35PM +0800, Luan Shengde wrote:
build fail email message with raised error message
- lack commit url
- lack pubkey
- repo url for the commit url not in upstream
- commit not exist or not available
- no more available account on jumper server
Signed-off-by: Luan Shengde shdluan@163.com
lib/assign-account-fail-eamil.rb | 38 ++++++++++++++++++++++++++++++++
spell: eamil => email
On Fri, Nov 13, 2020 at 10:53:38AM +0800, Wu Fengguang wrote:
On Thu, Nov 12, 2020 at 07:26:35PM +0800, Luan Shengde wrote:
build fail email message with raised error message
- lack commit url
- lack pubkey
- repo url for the commit url not in upstream
- commit not exist or not available
- no more available account on jumper server
Signed-off-by: Luan Shengde shdluan@163.com
lib/assign-account-fail-eamil.rb | 38 ++++++++++++++++++++++++++++++++
spell: eamil => email
a mistake, I will fix it
Thanks, Luan Shengde
On Thu, Nov 12, 2020 at 07:26:35PM +0800, Luan Shengde wrote:
build fail email message with raised error message
- lack commit url
- lack pubkey
- repo url for the commit url not in upstream
- commit not exist or not available
- no more available account on jumper server
Signed-off-by: Luan Shengde shdluan@163.com
lib/assign-account-fail-eamil.rb | 38 ++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100755 lib/assign-account-fail-eamil.rb
diff --git a/lib/assign-account-fail-eamil.rb b/lib/assign-account-fail-eamil.rb new file mode 100755 index 0000000..1c2133c --- /dev/null +++ b/lib/assign-account-fail-eamil.rb @@ -0,0 +1,38 @@ +#!/usr/bin/env ruby +# SPDX-License-Identifier: MulanPSL-2.0+ +# Copyright (c) 2020 Huawei Technologies Co., Ltd. All rights reserved. +# frozen_string_literal: true
+def build_apply_account_fail_email(my_info, message)
- email_msg = <<~EMAIL_MESSAGE
- To: #{my_info['my_email']}
- Subject: [compass-ci] apply account failed
- Dear user:
Your application for account failed with following error:
正文不要缩进。
#{message}
In order to successfully apply an account, please pay attention to the following points:
1. mail subject
1.2.也不用缩进.
Thanks, Fengguang
the subject should exactly: apply account
2. commit url
when you writing the url, add prefix: my oss commit
example:
my oss commit: https://github.com/torvalds/aalinux/commit/7be74942f184fdfba34ddd19a0d995deb34d4a03
attention:
ensure you commit url exist and available to access.
3. ssh pubkey
you need to add a pubkey as an attachment with name 'id_rsa.pub' to the email.
- regards
- compass-ci
- EMAIL_MESSAGE
- return email_msg
+end
2.23.0
- Subject: [compass-ci] apply account failed
- Dear user:
Your application for account failed with following error:
正文不要缩进。
#{message}
In order to successfully apply an account, please pay attention to the following points:
1. mail subject
1.2.也不用缩进.
OK, I will fix them.
Thanks, Luan Shengde
Thanks, Fengguang
the subject should exactly: apply account
2. commit url
when you writing the url, add prefix: my oss commit
example:
my oss commit: https://github.com/torvalds/aalinux/commit/7be74942f184fdfba34ddd19a0d995deb34d4a03
attention:
ensure you commit url exist and available to access.
3. ssh pubkey
you need to add a pubkey as an attachment with name 'id_rsa.pub' to the email.
- regards
- compass-ci
- EMAIL_MESSAGE
- return email_msg
+end
2.23.0