Seeking help on jq installation using MacPorts
Sushma g
gsushma810 at gmail.com
Wed Jun 10 09:46:50 UTC 2020
Hi Andrew,
I tried the way as u suggested, but I was not able to install even with
commands in mac machine. PFB screenshot for your reference.
[image: image.png]
Regards,
Sushma
On Wed, 10 Jun 2020 at 00:13, Andrew Udvare <audvare at gmail.com> wrote:
> On 09/06/2020 07:51, Sushma g wrote:
> > Hi Team,
> >
> > I am trying to install jq on mac using ansible-playbook. I have used
> > Macports module available in ansible to achieve this task
> > Playbook-snippet
> > - name: install items
> > macports:
> > name: "{{ item }}"
> > state: present
> > with_items:
> > - jq
> > - openjdk11
> > - nodejs12
> > - git
> >
> > When I run this playbook the play is success and when I check for jq
> > installation using command "jq --version" seeing command not found error,
> > whereas other items like git and java are installed. Facing this issue
> only
> > for nodejs and jq
>
> Two possibilities:
>
> 1. items not being installed
> 2. PATH not set to include /opt/local/bin
>
> The reason Git and Java can work is because they are already in macOS
> even as wrappers before Developer Tools are installed:
>
> $ ls -la /usr/bin/java /usr/bin/git
> -rwxr-xr-x 1 root wheel 31488 2020-05-19 01:27:38 /usr/bin/git
> lrwxr-xr-x 1 root wheel 74 2019-07-20 07:09:55 /usr/bin/java ->
> /System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands/java
>
> SSH into the machine and run `port install jq` and make sure this
> actually can work.
>
> If you don't want to have to specify the full path to jq/etc, make sure
> to set PATH to prepend /opt/local/bin.
>
> One method is to do this for only the playbook or task:
>
>
> https://docs.ansible.com/ansible/latest/reference_appendices/faq.html#how-can-i-set-the-path-or-any-other-environment-variable-for-a-task-or-entire-playbook
>
> --
> Andrew
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macports.org/pipermail/macports-users/attachments/20200610/d1198ce3/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image.png
Type: image/png
Size: 19489 bytes
Desc: not available
URL: <http://lists.macports.org/pipermail/macports-users/attachments/20200610/d1198ce3/attachment.png>
More information about the macports-users
mailing list