Differences
This shows you the differences between two versions of the page.
howto:install_odroid_c1 [2017/03/24 10:52] guilarr [prequisites] |
howto:install_odroid_c1 [2018/12/08 22:28] |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ==== prequisites ==== | ||
- | * An [[http://www.hardkernel.com/main/products/prdt_info.php?g_code=G141578608433|Odroid C1]] | ||
- | * A SD card with a fresh install of [[https://www.armbian.com/odroid-c1/|ARMBian]] | ||
- | |||
- | ==== Installation ==== | ||
- | |||
- | the installation will not do the configuration or the "post_installation". This installation will just add yunohost + vpn component + hostap component. | ||
- | |||
- | <code> | ||
- | #!/bin/bash | ||
- | clear | ||
- | cat <<EOF | ||
- | ******************************************************************************** | ||
- | Vous êtes sur le point d'installer une brique Internet sur votre Odroid C1. | ||
- | Si votre 'PC' n'est pas un Odroid C1 fraichement installé avec une version | ||
- | ARMBian à jour, ce script n'est pas le bon à moins que vous sachiez ce que vous | ||
- | faites. | ||
- | Evidemment nous ne pourrons être tenu pour responsables des désagréments | ||
- | occasionnés suite à l'installation de ce composant. | ||
- | De même je tiens à vous avertir que l'utilisation d'une brique renforce votre | ||
- | anonymat sur Internet. Ceci dit si vous avez des intentions d'attaquer le FBI ou | ||
- | autre site sensible, assurément, la brique n'est pas le bon outil (et c'est pas bien). | ||
- | |||
- | L'installation nécessite une connection Internet. | ||
- | |||
- | Bref, ça fonctionne mais c'est mieux de savoir ce que vous faites. Si ce n'est pas le | ||
- | cas c'est une super occasion d'apprendre ;-) | ||
- | |||
- | amusez-vous bien! | ||
- | |||
- | Press any key to continue or CTRL-C to abort | ||
- | EOF | ||
- | read | ||
- | |||
- | |||
- | set_locales() { | ||
- | [ "$(grep LC_ALL /etc/environment)" ] || echo 'LC_ALL="en_US.UTF-8"' >> /etc/environment | ||
- | source /etc/environment | ||
- | export LC_ALL | ||
- | } | ||
- | |||
- | upgrade_system() { | ||
- | echo "Upgrading Debian packages..." | ||
- | set -x | ||
- | apt-get update #-qq | ||
- | apt-get dist-upgrade -y | ||
- | apt-get install git dialog -y | ||
- | git clone https://github.com/YunoHost/install_script /tmp/install_script | ||
- | #bug in the install_script | ||
- | mkdir /var/log/nginx | ||
- | cd /tmp/install_script && sudo ./install_yunohost -a | ||
- | |||
- | } | ||
- | |||
- | add_labriqueinternet_app_list() { | ||
- | echo "Adding labriqueinternet official app list for updates in the future..." | ||
- | yunohost app fetchlist -n labriqueinternet -u https://labriqueinter.net/apps/labriqueinternet.json | ||
- | } | ||
- | install_vpnclient() { | ||
- | echo "Installing the VPN client application..." | ||
- | set -x | ||
- | yunohost app install vpnclient | ||
- | } | ||
- | |||
- | install_hotspot() { | ||
- | echo "Installing the Hotspot application..." | ||
- | set -x | ||
- | yunohost app install hotspot --verbose | ||
- | } | ||
- | |||
- | install_doctorcube() { | ||
- | set -x | ||
- | echo "Installing doctorcube (this shouldn't do anything)..." | ||
- | yunohost app install doctorcube --verbose | ||
- | } | ||
- | |||
- | # ---------------------------------- | ||
- | # Optional steps | ||
- | # ---------------------------------- | ||
- | |||
- | remove_dyndns_cron() { | ||
- | set -x | ||
- | yunohost dyndns update > /dev/null 2>&1 \ | ||
- | && echo "Removing the DynDNS cronjob..." \ | ||
- | || echo "No DynDNS to remove" | ||
- | rm -f /etc/cron.d/yunohost-dyndns | ||
- | } | ||
- | |||
- | restart_api() { | ||
- | set -x | ||
- | systemctl restart yunohost-api | ||
- | } | ||
- | |||
- | cat <<EOF | ||
- | /!\\ Do not forget to change: | ||
- | * The root password on the OS-level: # passwd | ||
- | * The administration password in yunohost | ||
- | * The regular user password in yunohost | ||
- | * The VPN client password administered in yunohost | ||
- | * The Wifi AP password administered in yunohost | ||
- | EOF | ||
- | } | ||
- | |||
- | # ---------------------------------- | ||
- | # Operation order (you can deactivate some if your script has failed in the middle) | ||
- | # ---------------------------------- | ||
- | |||
- | |||
- | set_locales | ||
- | upgrade_system | ||
- | add_labriqueinternet_app_list | ||
- | install_vpnclient | ||
- | install_hotspot | ||
- | install_doctorcube | ||
- | remove_dyndns_cron | ||
- | restart_api | ||
- | |||
- | </code> |