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

Handle simple glob patterns when upgrading the sync patterns #2287

Merged

Conversation

corneliusweig
Copy link
Contributor

Also simple glob patterns are flattened at the destination. The translation to the new sync config was not handled correctly for cases such as:

- public/*: /app/public
- public/index.html: /app/public

Now, for compatible source patterns, the strip field is correctly populated. For example:
IN:

apiVersion: skaffold/v1beta8
kind: Config
build:
  artifacts:
  - image: myimage
    sync:
      public/*: /app/public

OUT (skaffold fix):

apiVersion: skaffold/v1beta11
kind: Config
build:
  artifacts:
  - image: myimage
    sync:
      manual:
      - src: public/*
        dest: /app/

This requires also a simplification of the sync rule, if strip is a suffix of dest, which is now also applied to triple-star patterns.

Fix #2280

Also simple glob patterns are flattened at the destination. The translation to the new sync config was not handled correctly for cases such as:
- public/*: /app/public
- public/index.html: /app/public

Signed-off-by: Cornelius Weig <22861411+corneliusweig@users.noreply.github.com>
@corneliusweig corneliusweig force-pushed the sync/fix-single-star-upgrade branch from c387824 to 74bede4 Compare June 18, 2019 19:23
@dgageot
Copy link
Contributor

dgageot commented Jun 19, 2019

Signed-off-by: Cornelius Weig <22861411+corneliusweig@users.noreply.github.com>
@corneliusweig corneliusweig force-pushed the sync/fix-single-star-upgrade branch from 74bede4 to b767165 Compare June 19, 2019 08:24
@corneliusweig
Copy link
Contributor Author

Whoops o_O .. fixed

@dgageot dgageot added the kokoro:run runs the kokoro jobs on a PR label Jun 19, 2019
@kokoro-team kokoro-team removed the kokoro:run runs the kokoro jobs on a PR label Jun 19, 2019
@dgageot dgageot merged commit 14bf34e into GoogleContainerTools:master Jun 19, 2019
@corneliusweig corneliusweig deleted the sync/fix-single-star-upgrade branch June 19, 2019 22:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Old sync config stops working
4 participants