Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Docker Build Images
scripts
Commits
8ef0273b
Commit
8ef0273b
authored
Mar 31, 2020
by
Markus Frosch
Browse files
rpm: Fix extra repositories for SLES < 12
parent
5dd11eec
Pipeline
#9074
passed with stage
in 24 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
functions-rpm.sh
View file @
8ef0273b
...
...
@@ -212,10 +212,15 @@ setup_extra_repository() {
)
|
sudo
bash
-c
"cat >'/etc/zypp/credentials.d/
${
extra_name
}
'"
fi
(
source
/etc/os-release
opt
=()
if
[
"
$ID
"
!=
sles
]
&&
[[
"
$VERSION
"
!=
11.
*
]]
;
then
opt+
=(
--priority
50
)
fi
set
-ex
sudo
zypper
--non-interactive
removerepo
"
${
extra_name
}
"
||
true
sudo
zypper
--non-interactive
addrepo
--priority
50
--refresh
"
${
extra_repository
}
"
"
${
extra_name
}
"
)
sudo
zypper
--non-interactive
addrepo
"
${
opt
[@]
}
"
--refresh
"
${
extra_repository
}
"
"
${
extra_name
}
"
)
||
exit
1
;;
*
)
# TODO: implement
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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