This repository was archived by the owner on Apr 9, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 157
This repository was archived by the owner on Apr 9, 2022. It is now read-only.
iso-generator assumes sudo is already configured #878
Copy link
Copy link
Open
Labels
bugBugs and errorsBugs and errors
Description
Basic info:
Anarchy version: git master
Installation method (VM/Host): inside lxd
System specifications (Processor, GPU, RAM ...): i7 / 32GB
What you expected would happen
I spun up a clean arch linux container in which I wanted to test building the installer iso.
lxc launch images:archlinux/current/amd64 arch
Jump in the container, install git, clone this repo and then run the installer.
lxc shell arch
pacman -Syyu git
git clone https://github.com/AnarchyLinux/installer
cd installer/
./iso-generator.sh
At this point I'd expect it to fail because sudo isn't setup.
What actually happened
It does indeed prompt to install many dependencies, but perhaps should do a pre-flight check on sudo.
-- Anarchy Linux --
30/09/2019 21:48 : Checking dependencies ...
error: package 'wget' was not found
error: package 'libisoburn' was not found
error: package 'squashfs-tools' was not found
error: package 'p7zip' was not found
error: package 'xxd' was not found
error: package 'gtk3' was not found
error: package 'pacman-contrib' was not found
error: package 'pkgconf' was not found
error: package 'patch' was not found
error: package 'gcc' was not found
error: package 'make' was not found
error: package 'binutils' was not found
error: package 'go' was not found
30/09/2019 21:48 : Missing dependencies: wget libisoburn squashfs-tools p7zip xxd gtk3 pacman-contrib pkgconf patch gcc make binutils go
Install them now? [y/N]:
y
30/09/2019 21:48 : Chose to install dependencies
30/09/2019 21:48 : Installing wget ...
./iso-generator.sh: line 170: sudo: command not found
30/09/2019 21:48 : User force stopped the script
Steps needed to reproduce the bug
These assume you have configured lxd/lxc correctly already.
lxc launch images:archlinux/current/amd64 arch
lxc shell arch
pacman -Syyu git
git clone https://github.com/AnarchyLinux/installer
cd installer/
./iso-generator.sh
## Possible fixes
Check early on in the script to see if we're root or if sudo is available, and abort with an appropriate error message.
## Bug report checklist
* [X] I've checked for any existing issues similar to mine and tried the solutions provided there
* [X] I've checked online for any existing fixes to my issue and added the link above
* [X] I've tried taking logs and submitting them above
Metadata
Metadata
Assignees
Labels
bugBugs and errorsBugs and errors