kubernetes / git-sync

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

Add /tmp to staging #794

Closed thockin closed 1 year ago

thockin commented 1 year ago

Fix #793

linux-foundation-easycla[bot] commented 1 year ago

CLA Signed

The committers listed above are authorized under a signed CLA.

thockin commented 1 year ago

/easycla

justinsb commented 1 year ago

I believe this will copy the permissions for /tmp (which are particularly important), because we use cp -a

LGTM though I wasn't sure whether you deliberately removed the dash symlink, so will add a hold but feel free to remove hold if deliberate.

/approve /lgtm /hold

k8s-ci-robot commented 1 year ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: justinsb, thockin

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

The pull request process is described here

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

/etc/shadow is not needed

The symlink to dash is already covered by the dash package (redundant)

This does retain /tmp permissions:

$ make container
<...lots ot output...>
container: gcr.io/k8s-staging-git-sync/git-sync:v4.0.0-rc4-1-g7a72116__linux_amd64

$ docker run -ti --entrypoint "" gcr.io/k8s-staging-git-sync/git-sync:v4.0.0-rc4-1-g7a72116__linux_amd64 ls -ld /tmp
drwxrwxrwt 2 root root 4096 Jul 31 15:18 /tmp