Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

find/use git, it is required to continue with installing #628

Closed
Sispheor opened this issue Oct 25, 2023 · 3 comments
Closed

find/use git, it is required to continue with installing #628

Sispheor opened this issue Oct 25, 2023 · 3 comments

Comments

@Sispheor
Copy link

Hi,

The install is complaining about Git not installed. Seems that system packages are installed AFTER galaxy libs. And so git is not yet present.
Should I add it in prepend step?
The dependencies should be a list so it can be executed with a defined order.

Here is my error:

#19 [galaxy 4/5] RUN ansible-galaxy role install  -r requirements.yml --roles-path "/usr/share/ansible/roles"
#19 0.682 [WARNING]: - ruzickap.proxy_settings was NOT installed successfully: could not
#19 0.682 find/use git, it is required to continue with installing
#19 0.682 https://github.com/ruzickap/ansible-role-proxy_settings.git
#19 0.683 ERROR! - you can use --ignore-errors to skip failed roles and finish processing the list.
#19 0.683 Starting galaxy role install process
#19 ERROR: process "/bin/sh -c ansible-galaxy role install $ANSIBLE_GALAXY_CLI_ROLE_OPTS -r requirements.yml --roles-path \"/usr/share/ansible/roles\"" did not complete successfully: exit code: 1
------
 > [galaxy 4/5] RUN ansible-galaxy role install  -r requirements.yml --roles-path "/usr/share/ansible/roles":
0.682 [WARNING]: - ruzickap.proxy_settings was NOT installed successfully: could not
0.682 find/use git, it is required to continue with installing
0.682 https://github.com/ruzickap/ansible-role-proxy_settings.git
0.683 ERROR! - you can use --ignore-errors to skip failed roles and finish processing the list.
0.683 Starting galaxy role install process
------
Dockerfile:45
--------------------
  43 |     WORKDIR /build
  44 |     
  45 | >>> RUN ansible-galaxy role install $ANSIBLE_GALAXY_CLI_ROLE_OPTS -r requirements.yml --roles-path "/usr/share/ansible/roles"
  46 |     RUN ANSIBLE_GALAXY_DISABLE_GPG_VERIFY=1 ansible-galaxy collection install $ANSIBLE_GALAXY_CLI_COLLECTION_OPTS -r requirements.yml --collections-path "/usr/share/ansible/collections"
  47 |     
--------------------
ERROR: failed to solve: process "/bin/sh -c ansible-galaxy role install $ANSIBLE_GALAXY_CLI_ROLE_OPTS -r requirements.yml --roles-path \"/usr/share/ansible/roles\"" did not complete successfully: exit code: 1

My conf:

version: 3
images:
  base_image:
    name: quay.io/rockylinux/rockylinux:9
dependencies:
  python_interpreter:
    package_system: python3.11
    python_path: /usr/bin/python3.11
  ansible_core:
    package_pip: ansible-core~=2.15
  ansible_runner:
    package_pip: ansible-runner~=2.3
  system: bindep.txt
  python: requirements.txt
  galaxy: requirements.yml

additional_build_files:
  - src: ansible.cfg
    dest: configs

additional_build_steps:

  append_base:
    - RUN alternatives --install /usr/bin/python3 python3 /usr/bin/python3.10 0
    - RUN cat /etc/os-release

bindep.txt:

# The gcc compiler
gcc

# Base requirements for RPM distros
gcc-c++           [platform:rpm]
git               [platform:rpm]
libffi-devel      [platform:rpm]
openssl-devel     [platform:rpm]
python3-devel     [platform:rpm]
python38-devel     [platform:rpm]
openldap-devel     [platform:rpm]

# For SELinux
python3-libselinux  [platform:redhat]
python3-libsemanage [platform:redhat]

# Required for compressing collected log files in CI
gzip

Thanks for you support !

@github-actions github-actions bot added the needs_triage New item that needs to be triaged label Oct 25, 2023
@Sispheor
Copy link
Author

Workaround:

additional_build_steps:
  prepend_base: |
    RUN dnf install -y git

@Shrews
Copy link
Contributor

Shrews commented Oct 25, 2023

The system dependencies are installed in the final image. So yes, you will need to install git in either a prepend_base or prepend_galaxy step, as in your workaround.

@Sispheor
Copy link
Author

Roger that. Thanks !

@Shrews Shrews removed the needs_triage New item that needs to be triaged label Dec 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants