Comments (3)
Hi @staticdev, thanks for reporting this issue.
There are two things at play here. Firstly, this role doesn't work by changing the symbolic links, it works by changing the PATH
environment variable. Both approaches have pros and cons, but I generally favor changing the PATH
when there's more than one executable. Secondly, there's the precedence of the Go installation in the PATH
, it was added to the end of the PATH
(lowest precedence). I've released version 3.0.0
of this role, which now adds this to the start of the PATH
(highest precedence), so it should override the Go installed as an OS package.
For this to work /etc/profile.d/golang.sh
needs to be sourced by your shell, this is normally sourced indirectly by sourcing /etc/profile
. If you're using Go from an interactive shell /etc/profile
will probably be sourced for you by the standard initialization scripts.
from ansible-role-golang.
Thanks for the explanation @freemanjp, I will try version 3.0.0 then ;)
from ansible-role-golang.
It is ok, I see it works so closing this.
from ansible-role-golang.
Related Issues (8)
- Support for armv6/7 HOT 2
- Update to Go 1.8.3
- Deprecation Warning HOT 1
- 'ansible_pkg_mgr' is undefined\n\nThe error appears to be in '/srv/ansible/roles/gantsign.golang/tasks/main.yml': HOT 1
- Not working when become: yes HOT 2
- `The task includes an option with an undefined variable.` HOT 1
- Go package won't upgrade if role re-played
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ansible-role-golang.