Skip CI if label added to PR (#2571)
Signed-off-by: Sanket Sudake <sanketsudake@gmail.com> Signed-off-by: Sanket Sudake <sanketsudake@gmail.com>
This commit is contained in:
@@ -22,7 +22,7 @@ on:
|
||||
jobs:
|
||||
CodeQL-Build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
if: ${{ !contains(github.event.pull_request.labels.*.name, 'skip-ci') }}
|
||||
steps:
|
||||
- name: Check out code
|
||||
uses: actions/checkout@v3
|
||||
|
||||
@@ -16,7 +16,7 @@ on:
|
||||
jobs:
|
||||
lint-dashboards:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
if: ${{ !contains(github.event.pull_request.labels.*.name, 'skip-ci') }}
|
||||
steps:
|
||||
- name: Check out code
|
||||
uses: actions/checkout@v3
|
||||
|
||||
@@ -24,7 +24,7 @@ env:
|
||||
jobs:
|
||||
lint:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
if: ${{ !contains(github.event.pull_request.labels.*.name, 'skip-ci') }}
|
||||
steps:
|
||||
- name: Check out code
|
||||
uses: actions/checkout@v3
|
||||
|
||||
@@ -29,6 +29,7 @@ jobs:
|
||||
# Job to run change detection
|
||||
integration-test:
|
||||
runs-on: ${{ matrix.os }}
|
||||
if: ${{ !contains(github.event.pull_request.labels.*.name, 'skip-ci') }}
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
|
||||
@@ -28,6 +28,7 @@ env:
|
||||
jobs:
|
||||
upgrade-test:
|
||||
runs-on: ${{ matrix.os }}
|
||||
if: ${{ !contains(github.event.pull_request.labels.*.name, 'skip-ci') }}
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
@@ -86,6 +87,7 @@ jobs:
|
||||
&& install_fission_cli
|
||||
|
||||
- name: Test previously created fission objects with new release
|
||||
timeout-minutes: 10
|
||||
run: |
|
||||
source ./test/upgrade_test/fission_objects.sh test_fission_objects
|
||||
|
||||
@@ -100,10 +102,10 @@ jobs:
|
||||
kind export logs --name kind kind-logs
|
||||
|
||||
- name: Archive fission dump
|
||||
if: ${{ failure() }}
|
||||
if: ${{ failure() || cancelled() }}
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: fission-dump
|
||||
name: fission-dump-${{ github.run_id }}-${{ matrix.kindversion }}
|
||||
path: fission-dump/*.zip
|
||||
retention-days: 5
|
||||
|
||||
|
||||
+4
-4
@@ -44,7 +44,7 @@ func UrlForFunction(name, namespace string) string {
|
||||
if namespace != metav1.NamespaceDefault {
|
||||
prefix = fmt.Sprintf("/fission-function/%s", namespace)
|
||||
}
|
||||
return fmt.Sprintf("%v/%v", prefix, name)
|
||||
return fmt.Sprintf("%s/%s", prefix, name)
|
||||
}
|
||||
|
||||
// IsNetworkError returns true if an error is a network error, and false otherwise.
|
||||
@@ -55,7 +55,7 @@ func IsNetworkError(err error) bool {
|
||||
|
||||
// GetFunctionIstioServiceName return service name of function for istio feature
|
||||
func GetFunctionIstioServiceName(fnName, fnNamespace string) string {
|
||||
return fmt.Sprintf("istio-%v-%v", fnName, fnNamespace)
|
||||
return fmt.Sprintf("istio-%s-%s", fnName, fnNamespace)
|
||||
}
|
||||
|
||||
// GetTempDir creates and return a temporary directory
|
||||
@@ -76,11 +76,11 @@ func FindAllGlobs(paths ...string) ([]string, error) {
|
||||
// use absolute path to find files
|
||||
path, err := filepath.Abs(p)
|
||||
if err != nil {
|
||||
return nil, errors.Wrapf(err, "error getting absolute path of path '%v'", p)
|
||||
return nil, errors.Wrapf(err, "error getting absolute path of path '%s'", p)
|
||||
}
|
||||
globs, err := filepath.Glob(path)
|
||||
if err != nil {
|
||||
return nil, errors.Errorf("invalid glob %v: %v", path, err)
|
||||
return nil, errors.Errorf("invalid glob %s: %s", path, err)
|
||||
}
|
||||
files = append(files, globs...)
|
||||
// xxx handle excludeGlobs here
|
||||
|
||||
Reference in New Issue
Block a user