ansible-role-git
ansible-role-git copied to clipboard
install_from_source causes repeated builds when prefix is not the default
Hi, I'm using your playbook with the following vars:
git_version: 2.26.2
git_install_from_source: true
git_install_from_source_force_update: true
git_install_path: "/opt"
It looks as if the custom install prefix is causing the version check to fail on repeated runs.
I can probably submit a patch over the weekend if you like?
Hi, i am using this and it fails but not on a repeated run. ( ansible-role.git version: 2.1.0 on redhat)
I get this error
msg: No package matching 'subversion-perl' found available, installed or updated
when i use these vars:
- { role: geerlingguy.git, git_version: '2.21.0', git_install_from_source: true, git_install_from_source_force_update: true }
what's the fix?
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!
Please read this blog post to see the reasons why I mark issues as stale.
I think I've fixed the original issue here. Should I open a PR?
Not sure about your problem @viresh-contino, sorry!
This issue is no longer marked for closure.
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!
Please read this blog post to see the reasons why I mark issues as stale.
boop
This issue is no longer marked for closure.
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!
Please read this blog post to see the reasons why I mark issues as stale.
Here's an easy repro for the issue:
$ tail -n +1 Dockerfile playbook.yml vars/main.yml
==> Dockerfile <==
FROM centos:8
RUN : \
&& dnf -q -y update \
&& dnf -q -y install epel-release \
&& dnf -q -y install ansible git \
&& :
RUN mkdir /tmp/t
COPY playbook.yml /tmp/t/
COPY vars /tmp/t/vars
RUN : \
&& cd /tmp/t \
&& ansible-galaxy install geerlingguy.git --force \
# && ansible-galaxy install git+https://github.com/rkm/ansible-role-git \
&& ansible-playbook playbook.yml \
&& ansible-playbook playbook.yml \
&& :
==> playbook.yml <==
- hosts: localhost
become: true
tasks:
- name: Include vars
include_vars: vars/main.yml
- name: Run geerlingguy.git
include_role:
name: geerlingguy.git
# name: ansible-role-git
==> vars/main.yml <==
git_version: 2.30.0
git_install_from_source: true
git_install_from_source_force_update: true
git_install_path: "/opt"
Building the Dockerfile results in git being built twice, since the version built in the initial run is not detected.
I believe the patch I suggested in #52 addresses this, which can be tested by switching the comments in the above Dockerfile and playbook.
This issue is no longer marked for closure.
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!
Please read this blog post to see the reasons why I mark issues as stale.
boop
This issue is no longer marked for closure.
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!
Please read this blog post to see the reasons why I mark issues as stale.
ping
This issue is no longer marked for closure.
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!
Please read this blog post to see the reasons why I mark issues as stale.
boop
This issue is no longer marked for closure.
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!
Please read this blog post to see the reasons why I mark issues as stale.
boop
This issue is no longer marked for closure.
This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!
Please read this blog post to see the reasons why I mark issues as stale.
This issue has been closed due to inactivity. If you feel this is in error, please reopen the issue or file a new issue with the relevant details.