On Wed, Oct 14, 2020 at 10:28:02AM +0800, Wu Fengguang wrote:
On Tue, Oct 13, 2020 at 09:23:20AM +0800, Luan Shengde wrote:
+require_relative '../defconfig.rb'
Blank line here. Have you run rubocop?
Yes I have run and returns no offenses detected I will add blank line here
+docker_rm 'mail-robot'
+JUMPER_IP = '192.168.132.2'
IP => HOST
I got it
+JUMPER_PORT = '29999' +SEND_MAIL_PORT = '11311'
Load from defaults?
container/assign-account/answerback-email.rb:56:SEND_MAIL_PORT = defaults['SEND_MAIL_PORT']
I got it and will optimize it.
+cmd = %W[
- docker run
- --restart=always
- --name=mail-robot
- -d
- -e JUMPER_IP=#{JUMPER_IP}
- -e JUMPER_PORT=#{JUMPER_PORT}
- -e SEND_MAIL_PORT=#{SEND_MAIL_PORT}
- -v /c/upstream-repos:/upstream-repos:ro
- -v /srv/cci/Maildir:/Maildir:rw
- -v /c/compass-ci:/compass-ci:ro
Please keep same dir name for consistency.
do you mean?
-v /c/upstream-repos:/c/upstream-repos:ro -v /srv/cci/Maildir:/srv/cci/Maildir:rw -v /c/compass-ci:/c/compass-ci:ro
- mail-robot
+]
+cmd += ['bash', '-c', 'umask 002 && ruby ./mail-robot.rb']
Set umask in ruby script?
I will optimize it
Thanks Luan Shengde
+system(*cmd)
2.23.0