Changing some files related to the update process
This commit is contained in:
parent
9382a1fd9f
commit
b2d153bb17
@ -2,7 +2,7 @@
|
||||
<div class="controls" v-if="display">
|
||||
<i class="off-icon" v-on:click="action('shutdown')" v-if="off_available"></i>
|
||||
<i class="quit-icon" v-on:click="action('quit')" v-if="quit_available"></i>
|
||||
<i :class="[ update_available ? 'update-icon' :'no-update-icon' ]" v-if="update_possibe" @click="$router.push({ name: 'update' })"></i>
|
||||
<i :class="[ update_available ? 'update-icon' :'no-update-icon' ]" @click="$router.push({ name: 'update' })"></i>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
|
@ -50,6 +50,7 @@ frontend:
|
||||
sparklines: true
|
||||
virtual_keyboard: true
|
||||
user_lang: userlang
|
||||
update: updateoption
|
||||
|
||||
# NETWORK -
|
||||
# Some elements related to the network configuration, such as
|
||||
|
13
install.sh
13
install.sh
@ -97,6 +97,19 @@ set_kioskmode() {
|
||||
fi
|
||||
}
|
||||
|
||||
set_update() {
|
||||
echo -n "[?] Do you want to be able to update TinyCheck from the frontend interface? [Yes/No] "
|
||||
read answer
|
||||
if [[ "$answer" =~ ^([yY][eE][sS]|[yY])$ ]]
|
||||
then
|
||||
sed -i "s/updateoption/true/g" /usr/share/tinycheck/config.yaml
|
||||
echo -e "\e[92m [✔] You'll be able to update it from the frontend!\e[39m"
|
||||
else
|
||||
sed -i "s/updateoption/false/g" /usr/share/tinycheck/config.yaml
|
||||
echo -e "\e[92m [✔] You'll need to pass by the console script to update TinyCheck.\e[39m"
|
||||
fi
|
||||
}
|
||||
|
||||
create_directory() {
|
||||
# Create the TinyCheck directory and move the whole stuff there.
|
||||
echo -e "[+] Creating TinyCheck folder under /usr/share/"
|
||||
|
@ -7,7 +7,7 @@ fi
|
||||
if [ $PWD = "/usr/share/tinycheck" ]; then
|
||||
echo "[+] Cloning the current repository to /tmp/"
|
||||
rm -rf /tmp/tinycheck/ &> /dev/null
|
||||
cd /tmp/ && git clone https://github.com/KasperskyLab/tinycheck
|
||||
cd /tmp/ && git clone --branch update-feature https://github.com/KasperskyLab/tinycheck
|
||||
cd /tmp/tinycheck && bash update.sh
|
||||
elif [ $PWD = "/tmp/tinycheck" ]; then
|
||||
|
||||
@ -61,6 +61,10 @@ elif [ $PWD = "/tmp/tinycheck" ]; then
|
||||
sed -i 's/analysis:/analysis:\n active: true/g' /usr/share/tinycheck/config.yaml
|
||||
fi
|
||||
|
||||
if ! grep -q update /usr/share/tinycheck/config.yaml; then
|
||||
sed -i 's/frontend:/frontend:\n update: true/g' /usr/share/tinycheck/config.yaml
|
||||
fi
|
||||
|
||||
if ! grep -q "CN=R3,O=Let's Encrypt,C=US" /usr/share/tinycheck/config.yaml; then
|
||||
sed -i "s/free_issuers:/free_issuers:\n - CN=R3,O=Let's Encrypt,C=US/g" /usr/share/tinycheck/config.yaml
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user