diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5726cb681..2f1195eb3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -3,12 +3,12 @@ name: Github-action-demo on: pull_request: branches: - - master + - 1.23k8s types: - closed push: branches: - - master + - 1.23k8s jobs: build: @@ -35,11 +35,25 @@ jobs: - name: report image with: # Runtime to use for the enrichment. - CF_RUNTIME_NAME: 'codefresh-hosted' + CF_RUNTIME_NAME: 'test-date' + + # CF_PLATFORM_URL: https://app-staging.codefresh.io + # CF_API_KEY: ${{secrets.CF_API_KEY_STAGING}} + + # CF_PLATFORM_URL: 'https://pre-prod.codefresh.io' + # CF_API_KEY: ${{secrets.CF_API_KEY}} + # CF_API_KEY: ${{secrets.CF_API_KEY_TEST}} + # CF_API_KEY: ${{secrets.CF_API_KEY_FREE}} + # CF_API_KEY: ${{secrets.CF_API_KEY_PRE_PROD}} + + # CF_RUNTIME_NAME: 'codefresh-onprem' + CF_PLATFORM_URL: 'https://hermes-onprem-test.cf-op.com' + CF_API_KEY: ${{secrets.CF_API_KEY_ONPREM}} # API key for authentication to Codefresh. !! Committing a plain text token is a security risk. We highly recommend using encrypted secrets. !! # Documentation - https://docs.github.com/en/actions/security-guides/encrypted-secrets - CF_API_KEY: ${{secrets.CF_API_KEY}} + + # Image reported and enriched in Codefresh. Pass the [account-name]/[image-name]:[tag] built in your CI. CF_IMAGE: ${{env.CF_IMAGE}} @@ -67,7 +81,7 @@ jobs: - name: Checkout csdp-salesdemo_applications uses: actions/checkout@v3 with: - repository: PiBog/rollouts-demo # change to real repo + repository: alina-codefresh/rollouts-demo # change to real repo path: . - name: Update application version run: | diff --git a/canary-rollout/canary-ingress.yaml b/canary-rollout/canary-ingress.yaml index a5c4a7cde..db0d29295 100644 --- a/canary-rollout/canary-ingress.yaml +++ b/canary-rollout/canary-ingress.yaml @@ -1,4 +1,4 @@ -apiVersion: networking.k8s.io/v1beta1 +apiVersion: networking.k8s.io/v1 kind: Ingress metadata: name: canary-demo @@ -8,10 +8,13 @@ metadata: ingress.kubernetes.io/app-root: / spec: rules: - - host: mr-solo-company-59ac69a.cf-cd.com + - host: canary.dev.argoproj.io http: paths: - path: / + pathType: ImplementationSpecific backend: - serviceName: canary-demo - servicePort: 80 + service: + name: canary-demo + port: + number: 80 \ No newline at end of file diff --git a/canary-rollout/canary-preview-ingress.yaml b/canary-rollout/canary-preview-ingress.yaml index 683e77578..123f6309e 100644 --- a/canary-rollout/canary-preview-ingress.yaml +++ b/canary-rollout/canary-preview-ingress.yaml @@ -1,4 +1,4 @@ -apiVersion: networking.k8s.io/v1beta1 +apiVersion: networking.k8s.io/v1 kind: Ingress metadata: name: canary-demo-preview @@ -12,6 +12,9 @@ spec: http: paths: - path: / + pathType: ImplementationSpecific backend: - serviceName: canary-demo-preview - servicePort: 80 + service: + name: canary-demo-preview + port: + number: 80 \ No newline at end of file diff --git a/canary-rollout/canary-rollout.yaml b/canary-rollout/canary-rollout.yaml index 0b4a89f00..e55d39488 100644 --- a/canary-rollout/canary-rollout.yaml +++ b/canary-rollout/canary-rollout.yaml @@ -15,7 +15,7 @@ spec: spec: containers: - name: canary-demo - image: boblinger/rollouts-demo:red + image: alina1test/rollouts-demo:blue imagePullPolicy: Always ports: - name: http @@ -27,7 +27,7 @@ spec: cpu: 5m strategy: canary: - canaryService: canary-demo-preview + #canaryService: canary-demo-preview steps: - setWeight: 20 - pause: {duration: 10} diff --git a/service.yaml b/service.yaml index a9d1386a1..a5b73ed2e 100644 --- a/service.yaml +++ b/service.yaml @@ -1 +1 @@ -red +green