8000 GitHub - StanAngeloff/longitude: A retired collection of Ansible playbooks to provision a (mostly) bootstrapped Ubuntu development desktop.   Moving to @StanAngeloff/nix-⁠meridian
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Feb 18, 2025. It is now read-only.
/ longitude Public archive

A retired collection of Ansible playbooks to provision a (mostly) bootstrapped Ubuntu development desktop.   Moving to @StanAngeloff/nix-⁠meridian

Notifications You must be signed in to change notification settings

StanAngeloff/longitude

Repository files navigation

Longitude

A collection of Ansible playbooks to provision a (mostly) bootstrapped Ubuntu development desktop.

Usage

This repository is tailor-made for my needs, be warned:

make playbook

Goals

  • The playbooks MUST be idempotent.
  • A reasonable attempt to secure most installations SHOULD be made (using checksums, signed packages, trusted sources, etc.)
  • No important actions SHOULD be carried by hand on the target system, any changes SHOULD be captured in this repository/playbooks.

Non-goals

  • There shall only be one operating system and version supported. I have zero interest in running anything but Ubuntu LTS at this time.
  • Configuring GNOME Shell is done manually (mostly dconf settings, e.g., extensions, tweaks, key maps, etc.)
  • Dotfiles are managed separately in a different repository.

Things to do first…

  1. Install Ubuntu Additional Drivers manually and reboot.
    These will provide a better hardware stack, e.g., graphics, web cam, etc.
  2. Install ubuntu-gnome-desktop (with gdm3) and reboot, switch the default session before logging in.
    Ubuntu comes with Unity out of the box which is… 💩
  3. Remove unity* using apt.
    Burn it with 🔥
  4. Install security updates apt update && apt upgrade (and perhaps apt dist-upgrade) followed by a reboot.
    Be warned, the latter may bump the kernel version and OEM drivers could break as a result, proceed with caution.
  5. Mess with ~/.fonts, Gnome Shell extensions, Gnome Tweak Tool, settings, personalisations, etc.
    • For rxvt-unicode to start, the following fonts are required: Input 1, Noto Mono 2, Symbola.

Further notes

  • Install ubuntu-restricted-extras to play DRM content on Netflix or watch YouTube/H.264 videos.
  • Consider using Cloudflare's public DNS 1.1.1.1 & 1.0.0.1 on all networks.
  • Set up a VPN with a dedicated IP (my preferred supplied is, and has always been, VPNUK). The dedicated IP will come in handy when setting up firewalls.
  • Oracle Java may still be needed to use government e-services. See Kamenitza Notepad’s blog post for more details.
    • Don't run update-alternatives --set, instead when prompted to run a .jnlp file in a browser, copy the URL to the file and use javaws from the Oracle package to launch it instead:

      /opt/java/64/jre*/bin/javaws 'https://inetdec.nra.bg/ls/java/stampitls.jnlp'

Things to do later…

  • SSH:
    • Complete the installation by running google-authenticator and following the prompts.
  • Parcellite:
    • To hide the annoying bottom-left corner icon, change the startup script to include --no-icon
  • Keybase:
    • Complete the installation by running run_keybase and import public/private keys:
      $ keybase pgp export | gpg --import
      $ keybase pgp export -s | gpg --allow-secret-key-import --import
  • Firefox:
  • Android Studio:
    • Run Android Studio and complete the installation so the Android SDK is installed & available.
      • When prompted, specify the install path as /opt/android/sdk (the directory will be missing, you need to create it first).
  • Indexing Preferences (this applies to Ubuntu 16.04 and has since been removed in 18.04):
    • See Disable Tracker for detailed steps. Turning indexing & location options off stops the deamon from consuming too much CPU & memory.

Getting Java to work under Pale Moon

You'll need to download and unpack Oracle Java, then:

sudo ln -s /opt/java/64/jre1.8.0_251/lib/amd64/libnpjp2.so /usr/lib/mozilla/plugins/libnpjp2.so
mkdir -p /usr/local/lib64 && ln -s /usr/lib/x86_64-linux-gnu/libpcsclite.so.1.0.0 /usr/local/lib64/libpcsclite.so

You may now make use of severely outdated government websites.

tessdata_best – Best (most accurate) trained models for Tesseract

mkdir -p ~/.local/share/tesseract-ocr/5/tessdata
cd ~/.local/share/tesseract-ocr/5/tessdata
wget https://github.com/tesseract-ocr/tessdata_best/raw/main/bul.traineddata
wget https://github.com/tesseract-ocr/tessdata_best/raw/main/eng.traineddata
wget https://github.com/tesseract-ocr/tessdata_best/raw/main/osd.traineddata
cp -R /usr/share/tesseract-ocr/5/tessdata/{configs,tessconfigs,pdf.ttf} /home/stan/.local/share/tesseract-ocr/5/tessdata
sudo chown -R stan: /home/stan/.local/share/tesseract-ocr/5/tessdata/{configs,tessconfigs,pdf.ttf}
echo 'export TESSDATA_PREFIX="${HOME}/.local/share/tesseract-ocr/5/tessdata"' >> ~/.localrc_stan-latitude_gnu_linux
ocrmypdf
sudo apt install unpaper
pip3.8 install --user ocrmypdf

Development

As the playbooks grows, the system will inevitably accumulate cruft; as a result, installing/compiling a package may succeed with all dependencies having been met. This shall not necessarily be true when starting from scratch. To verify the playbooks' correctness on a vanilla Ubuntu system, use the provided Docker task:

make docker-playbook

This will start a new ephemeral container from a base Ubuntu image and run the playbooks from start to finish. 3

Experimental

The following additions and modules are still experimental and haven't been added to the playbook.

Alacritty

sudo apt install libxcb-shape0-dev libxcb-xfixes0-dev libegl1-mesa-dev
cd /data/public
git clone https://github.com/alacritty/alacritty.git
cd alacritty
git checkout 3bfc4c2808d7e3ea50fb84780b4c30140114b3b1
cargo build --release
cp -r target/release/ /opt/alacritty-0.11.0-3bfc4c2808
tic -xe alacritty,alacritty-direct extra/alacritty.info

You may want to modify urxvt launch files, too.

Footnotes

  1. My Input font preferences are: Input-BoldItalic_(InputMonoNarrow-BoldItalic).ttf, Input-Bold_(InputMonoNarrow-Bold).ttf, Input-Italic_(InputMonoNarrow-Italic).ttf & Input-Regular_(InputMonoNarrow-Regular).ttf. These are freely available.

  2. Noto is only needed for extended character sets, NotoMono-Regular.ttf should suffice.

  3. […] with the notable exception of Flakpaks which require a reboot.

About

A retired collection of Ansible playbooks to provision a (mostly) bootstrapped Ubuntu development desktop.   Moving to @StanAngeloff/nix-⁠meridian

Topics

Resources

Stars

Watchers

Forks

0