Skip to content

Commit

Permalink
chore: feature flags file (#555)
Browse files Browse the repository at this point in the history
  • Loading branch information
tmilos77 authored Sep 2, 2024
1 parent e64540d commit 5aa4ed0
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 11 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/pr-feature-toggles.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Feature toggles

on:
pull_request:

permissions:
contents: read
pull-requests: read
checks: write

jobs:
schema-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version-file: 'go.mod'
- name: Go details
run: |
go env
- name: Install jv
run: |
go install github.com/santhosh-tekuri/jsonschema/cmd/jv@latest
- name: Validate schema
run: |
SCHEMA_URL="https://raw.githubusercontent.com/thomaspoignant/go-feature-flag/v1.31.2/.schema/flag-schema.json"
jv --assert-content --assert-format $SCHEMA_URL ./config/featureToggles/featureToggles.yaml
6 changes: 4 additions & 2 deletions CODEOWNERS
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# Default owners of the `cloud-manager` repository
* @kyma-project/Phoenix

# All files and subdirectories in /docs
/docs/ @kyma-project/technical-writers

# All .md files
*.md @kyma-project/technical-writers

# Default owners of the `cloud-manager` repository
* @kyma-project/Phoenix
/config/featureToggles/featureToggles.yaml @kyma-project/phoenix-admins
16 changes: 7 additions & 9 deletions config/featureToggles/featureToggles.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

apiDisabled:
variations:
enabled: false
Expand All @@ -7,21 +6,20 @@ apiDisabled:
- name: All APIs are disabled for trial SKR
query: brokerPlan == "trial"
variation: disabled
- name: Enabled on stage for global account 6034adc9-3441-494c-b438-a0eba4c5045a
query: landscape == "stage" and globalAccount == "6034adc9-3441-494c-b438-a0eba4c5045a"
variation: enabled
- name: Disabled APIs on stage and prod
query: feature in ["nfsBackup", "peering"] and landscape != "dev"
query: feature in ["nfsBackup", "peering", "redis"] and landscape != "dev"
variation: disabled
defaultRule:
variation: enabled
ipRangeAutomaticCidrAllocation:
variations:
enabled: false
disabled: true
targeting:
- name: Enabled on dev 059dbc39-fd2b-4186-b0e5-8a1bc8ede5b8
query: landscape == "dev" and kyma == "059dbc39-fd2b-4186-b0e5-8a1bc8ede5b8"
variation: enabled
enabled: true
disabled: false
defaultRule:
variation: disabled
variation: enabled
gcpNfsVolumeAutomaticLocationAllocation:
variations:
enabled: true
Expand Down

0 comments on commit 5aa4ed0

Please sign in to comment.