- Hi, I’m the developer for warrensbox.
- For my tfswitch application, I need access for my application to read and write to
What is tfswitch?
tfswitch command line tool lets you switch between different versions of terraform.
If you do not have a particular version of terraform installed,
tfswitch will download the version you desire.
The installation is minimal and easy.
Once installed, simply select the version you require from the dropdown and start using terraform.
https://tfswitch.warrensbox.com/ for more info.
Why I need access to
terraform binaryinto $SNAP_USER_COMMON/.terraform.versions
tfswitchcreated a symlink
$SNAP_USER_COMMON/.terraform.versionsbut not all users have access to
tfswitchlets users to pass in their custom bin location. For example - $HOME/bin. User would later add $HOME/bin to their $PATH.
- For users that install
tswitchwith snapcraft, even if users are able to pass their own custom bin location ($HOME/bin), snapcraft does not let you create a symlink.
My solution was to use
interface: personal-files to read and write to
$HOME/bin . That way
tfswitch can still create a symlink for users while not being overly obtrusive.
Here the snippet of what I have:
plugs: home-bin: interface: personal-files read: - $HOME/bin write: - $HOME/bin
I appreciate any suggestions. Thank you!