1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/gitlab_ynh.git synced 2024-09-03 18:36:35 +02:00

Don't use sed -i

This commit is contained in:
Kayou 2019-03-16 12:29:00 +01:00
parent 0f0d38a7ba
commit a550bc2bc1
No known key found for this signature in database
GPG key ID: 823A2CBE071D3126
3 changed files with 3 additions and 3 deletions

View file

@ -136,7 +136,7 @@ ynh_setup_source $tempdir $architecture
if IS_PACKAGE_CHECK; then
dpkg -i $tempdir/$gitlab_filename || true # This command will fail in lxc env
sed -i 's/command \"cat \/etc\/sysctl.conf \/etc\/sysctl.d\/\*.conf | sysctl -e -p -\"/command \"cat \/etc\/sysctl.conf\"/g' $final_path/embedded/cookbooks/package/resources/sysctl.rb
ynh_replace_string "command \"cat \/etc\/sysctl.conf \/etc\/sysctl.d\/\*.conf | sysctl -e -p -\"" "command \"cat \/etc\/sysctl.conf\"" "$final_path/embedded/cookbooks/package/resources/sysctl.rb"
dpkg --configure gitlab-ce
else
dpkg -i $tempdir/$gitlab_filename

View file

@ -91,7 +91,7 @@ ynh_setup_source $tempdir $architecture
if IS_PACKAGE_CHECK; then
dpkg -i $tempdir/$gitlab_filename || true # This command will fail in lxc env
sed -i 's/command \"cat \/etc\/sysctl.conf \/etc\/sysctl.d\/\*.conf | sysctl -e -p -\"/command \"cat \/etc\/sysctl.conf\"/g' $final_path/embedded/cookbooks/package/resources/sysctl.rb
ynh_replace_string "command \"cat \/etc\/sysctl.conf \/etc\/sysctl.d\/\*.conf | sysctl -e -p -\"" "command \"cat \/etc\/sysctl.conf\"" "$final_path/embedded/cookbooks/package/resources/sysctl.rb"
dpkg --configure gitlab-ce
else
dpkg -i $tempdir/$gitlab_filename

View file

@ -175,7 +175,7 @@ ynh_setup_source $tempdir $architecture
if IS_PACKAGE_CHECK; then
dpkg -i $tempdir/$gitlab_filename || true # This command will fail in lxc env
sed -i 's/command \"cat \/etc\/sysctl.conf \/etc\/sysctl.d\/\*.conf | sysctl -e -p -\"/command \"cat \/etc\/sysctl.conf\"/g' $final_path/embedded/cookbooks/package/resources/sysctl.rb
ynh_replace_string "command \"cat \/etc\/sysctl.conf \/etc\/sysctl.d\/\*.conf | sysctl -e -p -\"" "command \"cat \/etc\/sysctl.conf\"" "$final_path/embedded/cookbooks/package/resources/sysctl.rb"
dpkg --configure gitlab-ce
else
dpkg -i $tempdir/$gitlab_filename