kubernetes / git-sync

A sidecar app which clones a git repo and keeps it in sync with the upstream.
Apache License 2.0
2.13k stars 406 forks source link

consistently use bash shebang for shell scripts #898

Closed sdowell closed 1 week ago

sdowell commented 1 week ago

This updates the build scripts to use a bash shebang for consistency with other scripts as well as better portability. If using a non-alpine BUILDIMAGE (e.g. debian) the build scripts are not valid sh syntax.

Also updates BUILDIMAGE to use the debian based golang image for consistency with BASEIMAGE. The debian based golang image also comes with bash installed, whereas the alpine base image does not.

k8s-ci-robot commented 1 week ago

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: sdowell Once this PR has been reviewed and has the lgtm label, please assign thockin for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files: - **[OWNERS](https://github.com/kubernetes/git-sync/blob/master/OWNERS)** Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
sdowell commented 1 week ago

/assign @thockin

thockin commented 1 week ago

I went the other way and made them more sh compatible.

sdowell commented 1 week ago

I went the other way and made them more sh compatible.

Can we switch the BUILDIMAGE to debian for better consistency? Why use alpine?