ci: fix git dubious permissions error #27423

pull josibake wants to merge 1 commits into bitcoin:master from josibake:josibake-git-dubious-dir-permissions changing 1 files +3 −0
  1. josibake commented at 11:40 AM on April 5, 2023: member

    fixes #27376 (comment)

    this appears to be caused by a more recent version of git being sensitive to mismatched permissions on directories. we didn't notice this before because we were using two separate user accounts to fix up dir permissions in the container , but the second account was removed in #27376

    there might be a more elegant way to do this, but this does the trick and seems to be the way others are fixing this issue around the internets.

  2. DrahtBot commented at 11:40 AM on April 5, 2023: contributor

    <!--e57a25ab6845829454e8d69fc972939a-->

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    <!--021abf342d371248e50ceaed478a90ca-->

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    ACK hebasto, RandyMcMillan
    Concept ACK fanquake

    If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.

    <!--174a7506f384e20aa4161008e828411d-->

    Conflicts

    Reviewers, this pull request conflicts with the following ones:

    • #27340 (ci: Use Cirrus CI dockerfile env by MarcoFalke)

    If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

  3. DrahtBot added the label Tests on Apr 5, 2023
  4. josibake commented at 11:42 AM on April 5, 2023: member
  5. in ci/test/04_install.sh:61 in 2c11e94131 outdated
      56 | @@ -57,6 +57,9 @@ if [ -z "$DANGER_RUN_CI_ON_HOST" ]; then
      57 |    export CI_EXEC_CMD_PREFIX="docker exec ${CI_CONTAINER_ID}"
      58 |    $CI_EXEC_CMD_PREFIX rsync --archive --stats --human-readable /ci_base_install/ "${BASE_ROOT_DIR}"
      59 |    $CI_EXEC_CMD_PREFIX rsync --archive --stats --human-readable /ro_base/ "$BASE_ROOT_DIR"
      60 | +  # Fixes permission issues when there is a container UID/GID mismatch with the owner
      61 | +  # # of the mounted bitcoin src dir.
    


    hebasto commented at 12:18 PM on April 5, 2023:

    A stray #?


    josibake commented at 12:25 PM on April 5, 2023:

    fixed

  6. hebasto approved
  7. hebasto commented at 12:18 PM on April 5, 2023: member

    ACK 2c11e94131447bc605b7698a80d02c2523497a4b, tested on Ubuntu 22.04.

  8. ci: fix git dubious permissions error ed4a8339b8
  9. josibake force-pushed on Apr 5, 2023
  10. hebasto approved
  11. hebasto commented at 12:37 PM on April 5, 2023: member

    re-ACK ed4a8339b8fe796b4668e206d7fb9c2b120f8eb2

  12. fanquake commented at 7:18 PM on April 5, 2023: member

    Concept ACK - will test

  13. RandyMcMillan commented at 8:49 PM on April 5, 2023: contributor

    ACK ed4a833

  14. in ci/test/04_install.sh:62 in ed4a8339b8
      56 | @@ -57,6 +57,9 @@ if [ -z "$DANGER_RUN_CI_ON_HOST" ]; then
      57 |    export CI_EXEC_CMD_PREFIX="docker exec ${CI_CONTAINER_ID}"
      58 |    $CI_EXEC_CMD_PREFIX rsync --archive --stats --human-readable /ci_base_install/ "${BASE_ROOT_DIR}"
      59 |    $CI_EXEC_CMD_PREFIX rsync --archive --stats --human-readable /ro_base/ "$BASE_ROOT_DIR"
      60 | +  # Fixes permission issues when there is a container UID/GID mismatch with the owner
      61 | +  # of the mounted bitcoin src dir.
      62 | +  $CI_EXEC_CMD_PREFIX git config --global --add safe.directory "*"
    


    maflcko commented at 7:31 AM on April 6, 2023:

    Not sure if it matters, but it could make sense to run this even when CI is run without the docker wrapper. Probably this doesn't affect anyone, but less conditional code seems a win by itself.


    maflcko commented at 9:13 AM on April 6, 2023:

    Had to do this here anyway: #27429

  15. maflcko approved
  16. maflcko commented at 7:33 AM on April 6, 2023: member

    lgtm

  17. fanquake merged this on Apr 6, 2023
  18. fanquake closed this on Apr 6, 2023

  19. sidhujag referenced this in commit 9d5a44baca on Apr 6, 2023
  20. josibake deleted the branch on Jan 26, 2024
  21. bitcoin locked this on Jan 25, 2025

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-18 12:13 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me