Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Debian QA
jenkins.debian.net
Commits
00daf62a
Unverified
Commit
00daf62a
authored
Dec 22, 2016
by
Holger Levsen
Browse files
reproducible Debian: use sudo -H
Signed-off-by:
Holger Levsen
<
holger@layer-acht.org
>
parent
eea2e1db
Changes
1
Hide whitespace changes
Inline
Side-by-side
update_jdn.sh
View file @
00daf62a
...
@@ -687,12 +687,12 @@ fi
...
@@ -687,12 +687,12 @@ fi
#
#
# Create GPG key for jenkins user if they do not already exist (eg. to sign .buildinfo files)
# Create GPG key for jenkins user if they do not already exist (eg. to sign .buildinfo files)
#
#
if
sudo
-u
jenkins gpg
--with-colons
--fixed-list-mode
--list-secret-keys
|
cut
-d
:
-f1
|
grep
-qsFx
'sec'
>
/dev/null 2>&1
;
then
if
sudo
-H
-u
jenkins gpg
--with-colons
--fixed-list-mode
--list-secret-keys
|
cut
-d
:
-f1
|
grep
-qsFx
'sec'
>
/dev/null 2>&1
;
then
explain
"
$(
date
)
- Not generating GPG key as one already exists for jenkins user."
explain
"
$(
date
)
- Not generating GPG key as one already exists for jenkins user."
else
else
explain
"
$(
date
)
- Generating GPG key for jenkins user."
explain
"
$(
date
)
- Generating GPG key for jenkins user."
sudo
-u
jenkins gpg
--no-tty
--batch
--gen-key
<<
EOF
sudo
-H
-u
jenkins gpg
--no-tty
--batch
--gen-key
<<
EOF
Key-Type: RSA
Key-Type: RSA
Key-Length: 4096
Key-Length: 4096
Key-Usage: sign
Key-Usage: sign
...
@@ -704,7 +704,7 @@ Expire-Date: 0
...
@@ -704,7 +704,7 @@ Expire-Date: 0
%commit
%commit
EOF
EOF
GPG_KEY_ID
=
"
$(
sudo
-u
jenkins gpg
--with-colons
--fixed-list-mode
--list-secret-keys
|
grep
'^sec'
|
cut
-d
:
-f5
|
tail
-n1
)
"
GPG_KEY_ID
=
"
$(
sudo
-H
-u
jenkins gpg
--with-colons
--fixed-list-mode
--list-secret-keys
|
grep
'^sec'
|
cut
-d
:
-f5
|
tail
-n1
)
"
if
[
"
$GPG_KEY_ID
"
=
""
]
if
[
"
$GPG_KEY_ID
"
=
""
]
then
then
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment