claircore icon indicating copy to clipboard operation
claircore copied to clipboard

layer: add filesystem MediaType

Open Maddosaurus opened this issue 9 months ago • 1 comments

To enable mounting of node filesystems, a new MediaType, application/x.filesystem+uncompressed, is introduced. The naming follows RFC6838 standards. As the fileystem does not provide a ReaderAt, the Reader function has been updated with a check to return an error if the layer does not have a ReaderAt.

This is tracked by https://issues.redhat.com/browse/ROX-22259

Maddosaurus avatar May 08 '24 09:05 Maddosaurus

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 56.29%. Comparing base (50f9052) to head (a883ddf).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1338      +/-   ##
==========================================
- Coverage   56.29%   56.29%   -0.01%     
==========================================
  Files         266      266              
  Lines       16812    16820       +8     
==========================================
+ Hits         9465     9468       +3     
- Misses       6385     6389       +4     
- Partials      962      963       +1     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar May 08 '24 09:05 codecov[bot]

As Matthias is off for few more days, I rebased and reworded the commit message to reflect the change in the custom media type. Is there anything that needs to be done here for the review?

vikin91 avatar Jun 11 '24 11:06 vikin91

Rebasing before the merge

vikin91 avatar Jun 14 '24 10:06 vikin91

/fast-forward

vikin91 avatar Jun 14 '24 11:06 vikin91

Triggered from https://github.com/quay/claircore/pull/1338#issuecomment-2167782945 by @​vikin91.

Trying to fast forward main (94e3ee6dd54c3cec9631d8fc4c3dd8de0e48725a) to maple/rox-22259-mediatype (8c32a63ab4d060765612f8bd8a0feb456da2385e).

Target branch (main):

commit 94e3ee6dd54c3cec9631d8fc4c3dd8de0e48725a (HEAD -> main, origin/main, origin/HEAD)
Author: Brad Lugo <[email protected]>
Date:   Sun Apr 21 21:18:12 2024 -0700

    tarfs: remove `ReadFile`
    
    Signed-off-by: Brad Lugo <[email protected]>

Pull request (maple/rox-22259-mediatype):

commit 8c32a63ab4d060765612f8bd8a0feb456da2385e (pull_request/maple/rox-22259-mediatype)
Author: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Date:   Mon May 27 03:04:00 2024 +0000

    layer: add filesystem MediaType
    
    To enable mounting of node filesystems, a new MediaType,
    'application/x-filesystem' is introduced.
    As the fileystem does not provide a ReaderAt, the Reader function has
    been updated with a check to return an error if the layer
    does not have a ReaderAt.
    
    Signed-off-by: Matthias Meidinger <[email protected]>
    Signed-off-by: Piotr Rygielski <[email protected]>

Sorry @vikin91, it is possible to fast forward main (94e3ee6dd54c3cec9631d8fc4c3dd8de0e48725a) to maple/rox-22259-mediatype (8c32a63ab4d060765612f8bd8a0feb456da2385e), but you don't appear to have permission to push to this repository.

github-actions[bot] avatar Jun 14 '24 11:06 github-actions[bot]

@crozzy could you help merging this?

vikin91 avatar Jun 14 '24 11:06 vikin91

/fast-forward

RTann avatar Jun 14 '24 20:06 RTann

Triggered from https://github.com/quay/claircore/pull/1338#issuecomment-2168709158 by @​RTann.

Trying to fast forward main (50f9052dafbf95eca002e15fef81ac1158b1c507) to maple/rox-22259-mediatype (8c32a63ab4d060765612f8bd8a0feb456da2385e).

Target branch (main):

commit 50f9052dafbf95eca002e15fef81ac1158b1c507 (HEAD -> main, origin/main, origin/HEAD)
Author: Joseph Crosland <[email protected]>
Date:   Tue May 21 11:59:15 2024 -0700

    libvuln: implement DeltaUpdateVulnerabilities for jsonblob store
    
    This change ensures that any updater that implement the delta update
    flow also have their vulnerabilities persisted in the jsonblob store.
    
    Signed-off-by: crozzy <[email protected]>

Pull request (maple/rox-22259-mediatype):

commit 8c32a63ab4d060765612f8bd8a0feb456da2385e (pull_request/maple/rox-22259-mediatype)
Author: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Date:   Mon May 27 03:04:00 2024 +0000

    layer: add filesystem MediaType
    
    To enable mounting of node filesystems, a new MediaType,
    'application/x-filesystem' is introduced.
    As the fileystem does not provide a ReaderAt, the Reader function has
    been updated with a check to return an error if the layer
    does not have a ReaderAt.
    
    Signed-off-by: Matthias Meidinger <[email protected]>
    Signed-off-by: Piotr Rygielski <[email protected]>

Can't fast forward main (50f9052dafbf95eca002e15fef81ac1158b1c507) to maple/rox-22259-mediatype (8c32a63ab4d060765612f8bd8a0feb456da2385e). main (50f9052dafbf95eca002e15fef81ac1158b1c507) is not a direct ancestor of maple/rox-22259-mediatype (8c32a63ab4d060765612f8bd8a0feb456da2385e). Branches appear to have diverged at 94e3ee6dd54c3cec9631d8fc4c3dd8de0e48725a:

* 8c32a63ab4d060765612f8bd8a0feb456da2385e layer: add filesystem MediaType
| * 50f9052dafbf95eca002e15fef81ac1158b1c507 libvuln: implement DeltaUpdateVulnerabilities for jsonblob store
|/  
* 94e3ee6dd54c3cec9631d8fc4c3dd8de0e48725a tarfs: remove `ReadFile`

commit 94e3ee6dd54c3cec9631d8fc4c3dd8de0e48725a
Author: Brad Lugo <[email protected]>
Date:   Sun Apr 21 21:18:12 2024 -0700

    tarfs: remove `ReadFile`
    
    Signed-off-by: Brad Lugo <[email protected]>

Rebase locally, and then force push to maple/rox-22259-mediatype.

github-actions[bot] avatar Jun 14 '24 20:06 github-actions[bot]

/fast-forward

RTann avatar Jun 14 '24 20:06 RTann

Triggered from https://github.com/quay/claircore/pull/1338#issuecomment-2168716829 by @​RTann.

Trying to fast forward main (50f9052dafbf95eca002e15fef81ac1158b1c507) to maple/rox-22259-mediatype (a883ddf3af0da1fc48f55c06f5aff3e3d5d9bfd9).

Target branch (main):

commit 50f9052dafbf95eca002e15fef81ac1158b1c507 (HEAD -> main, origin/main, origin/HEAD)
Author: Joseph Crosland <[email protected]>
Date:   Tue May 21 11:59:15 2024 -0700

    libvuln: implement DeltaUpdateVulnerabilities for jsonblob store
    
    This change ensures that any updater that implement the delta update
    flow also have their vulnerabilities persisted in the jsonblob store.
    
    Signed-off-by: crozzy <[email protected]>

Pull request (maple/rox-22259-mediatype):

commit a883ddf3af0da1fc48f55c06f5aff3e3d5d9bfd9 (pull_request/maple/rox-22259-mediatype)
Author: dependabot[bot] <dependabot[bot]@users.noreply.github.com>
Date:   Mon May 27 03:04:00 2024 +0000

    layer: add filesystem MediaType
    
    To enable mounting of node filesystems, a new MediaType,
    'application/x-filesystem' is introduced.
    As the fileystem does not provide a ReaderAt, the Reader function has
    been updated with a check to return an error if the layer
    does not have a ReaderAt.
    
    Signed-off-by: Matthias Meidinger <[email protected]>
    Signed-off-by: Piotr Rygielski <[email protected]>

Fast forwarding main (50f9052dafbf95eca002e15fef81ac1158b1c507) to maple/rox-22259-mediatype (a883ddf3af0da1fc48f55c06f5aff3e3d5d9bfd9).

$ git push origin a883ddf3af0da1fc48f55c06f5aff3e3d5d9bfd9:main
remote: error: GH006: Protected branch update failed for refs/heads/main.        
remote: error: 2 of 6 required status checks are in progress.        
To https://github.com/quay/claircore.git
 ! [remote rejected] a883ddf3af0da1fc48f55c06f5aff3e3d5d9bfd9 -> main (protected branch hook declined)
error: failed to push some refs to 'https://github.com/quay/claircore.git'

github-actions[bot] avatar Jun 14 '24 20:06 github-actions[bot]

/fast-forward

RTann avatar Jun 14 '24 20:06 RTann

finally

RTann avatar Jun 14 '24 20:06 RTann