Arch linux package errors out due to empty conditional in .INSTALL

Trying to install on arch linux via the install script, it errors out during the pacman install command. There seems to be an empty bash conditional in the .INSTALL script on line 11

:: Proceed with installation? [Y/n] 
(1/1) checking keys in keyring                                                   [##############################################] 100%
(1/1) checking package integrity                                                 [##############################################] 100%
(1/1) loading package files                                                      [##############################################] 100%
(1/1) checking for file conflicts                                                [##############################################] 100%
(1/1) checking available disk space                                              [##############################################] 100%
warning: could not get file information for pkgbuildinstallations1
:: Processing package changes...
(1/1) reinstalling twingate                                                      [##############################################] 100%
/tmp/alpm_BsLI98/.INSTALL: line 11: syntax error near unexpected token `fi'
/tmp/alpm_BsLI98/.INSTALL: line 11: `	fi'
/usr/bin/bash: line 1: post_upgrade: command not found
error: command failed to execute correctly
:: Running post-transaction hooks...
(1/2) Reloading system manager configuration...
(2/2) Arming ConditionNeedsUpdate...
2 Likes

Hey Pete,

Thanks for bringing this to our attention. I was able to recreate it so I have raised it with our Dev team and I’ll let you know what I find out!

Thanks,

-arthur

1 Like

i use arch too, with an arm64 device. I use debtap which you can find on the AUR to massage a deb into a usable pacman package.

I had the same issues…

curl https://binaries.twingate.com/client/linux/ARCH/x86_64/latest/twingate-amd64.pkg.tar.zst --output twingate.pkg.tar.zst
pacman -Syy

chmod 775 twingate.pkg.tar.zst

unarchive the tar.zst and manually edit the empty conditional statement on line 11

.INSTALL[file]

10: if [ ! -d /run/systemd/system ]; then
11: 	echo "empty conditional fail"
12: fi

save back to archive, then continue installation process.

pacman -U --noconfirm twingate.pkg.tar.zst

sudo twingate setup 
...

sudo twingate start

If you get this message about dir owner…

Failed to start twingated
err
Execution returned an error code with the message: Unexpected directory owner

or

Starting Twingate service
Failed to start twingated
Execution returned an error code with the message: Unexpected directory owner
Execution returned an error code with the message: twingate service-start failed

then check permissions and adjust accordingly for /etc/twingate

sudo chown -R root:root /etc/twingate
twingate start                                           
Starting Twingate service
Twingate has been started; user authentication is required for access to Resources
Starting UI notifications
Enabled desktop notifications

This seemed to do the trick for me on a fresh EndeavorOS install.
Good luck.

This is like a 1 minute patch, any chance this is fixed in a new version? Cost me quite a bit of time trying to get this to work.

Hey @Montana - I had been told this was resolved in a release a few months ago. I will investigate and follow up.

Sorry for the inconvenience.

-arthur

1 Like

No worries Arthur, thanks for looking out.

Hi @Montana – I can’t actually get things to error out on my install of Arch. Can you confirm that you’re up to date?

Can you post the output you see when trying to run the install script?

Thanks!

-arthur

I’ve worked around the issue I was having - other colleagues did not have similar issues but I am on EndeavorOS and not a vanilla Arch install. There’s also the chance I botched it. Anyway - everything is working great after the little haxxing I did. Seems like the “latest” version is patched?