Commit 1164037e authored by Jondy Zhao's avatar Jondy Zhao

Don't apply patch if the source has been patched.

parent 3078b5fd
...@@ -43,7 +43,7 @@ if [[ -f $patch_file ]] ; then ...@@ -43,7 +43,7 @@ if [[ -f $patch_file ]] ; then
for x in $(find $slapos_home/eggs -name slapos.core-*.egg ; do for x in $(find $slapos_home/eggs -name slapos.core-*.egg ; do
echo Patching $x ... echo Patching $x ...
cd $x cd $x
patch --dry-run -p1 < $patch_file && patch -p1 < $patch_file && echo Patch $x OK. patch -f --dry-run -p1 < $patch_file > /dev/null && patch -p1 < $patch_file && echo Patch $x OK.
done done
fi fi
......
...@@ -468,7 +468,6 @@ done ...@@ -468,7 +468,6 @@ done
#------------------------------------------------- #-------------------------------------------------
slaprunner_title="SlapOS-Node-Runner-In-$computer_id" slaprunner_title="SlapOS-Node-Runner-In-$computer_id"
grep -q "window.location.href" $slapos_runner_file grep -q "window.location.href" $slapos_runner_file
if (( $? )) ; then if (( $? )) ; then
echo echo
...@@ -487,7 +486,7 @@ if (( $? )) ; then ...@@ -487,7 +486,7 @@ if (( $? )) ; then
echo "Supply $slaprunner_cfg in the computer $computer_id" echo "Supply $slaprunner_cfg in the computer $computer_id"
/opt/slapos/bin/slapos supply $slaprunner_cfg $computer_id /opt/slapos/bin/slapos supply $slaprunner_cfg $computer_id
echo "Request an instance 'Node Runner' ..." echo "Request an instance $slaprunner_title ..."
while true ; do while true ; do
/opt/slapos/bin/slapos node software --verbose /opt/slapos/bin/slapos node software --verbose
/opt/slapos/bin/slapos node instance --verbose /opt/slapos/bin/slapos node instance --verbose
...@@ -530,7 +529,7 @@ EOF ...@@ -530,7 +529,7 @@ EOF
for x in $(find /opt/slapgrid/ -name slapos.cookbook-*.egg) ; do for x in $(find /opt/slapgrid/ -name slapos.cookbook-*.egg) ; do
echo Apply to $x echo Apply to $x
cd $x cd $x
patch --dry-run -p1 < $patch_file && patch -p1 < $patch_file patch -f --dry-run -p1 < $patch_file > /dev/null && patch -p1 < $patch_file
done done
fi fi
echo echo
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment