Skip to content

Merge pull request #91 from Pyrrha-Platform/dependabot/pip/flask-cors… #28

Merge pull request #91 from Pyrrha-Platform/dependabot/pip/flask-cors…

Merge pull request #91 from Pyrrha-Platform/dependabot/pip/flask-cors… #28

Workflow file for this run

# This workflow will build a docker container, publish it to IBM Container Registry,
# and deploy it to an existing IKS cluster
name: Build and Deploy Dev
on:
workflow_dispatch:
push: # Execute on every push to the master branch. Merging a pull request counts as a push.
branches:
- main
# Environment variables available to all jobs and steps in this workflow
env:
GITHUB_SHA: ${{ github.sha }}
IBM_CLOUD_API_KEY: ${{ secrets.IBM_CLOUD_API_KEY_DEV }}
IBM_CLOUD_REGION: ${{ secrets.IBM_CLOUD_REGION_DEV }}
IBM_CLOUD_RESOURCE_GROUP: ${{ secrets.IBM_CLOUD_RESOURCE_GROUP_DEV }}
ICR_REGION: ${{ secrets.ICR_REGION_DEV }}
ICR_NAMESPACE: ${{ secrets.ICR_NAMESPACE_DEV }}
ICR_REGISTRY_HOSTNAME: ${{secrets.ICR_REGISTRY_HOSTNAME_DEV}}
IKS_CLUSTER: ${{ secrets.IKS_CLUSTER_DEV }}
K8S_CLUSTER_NAMESPACE: ${{ secrets.K8S_CLUSTER_NAMESPACE_DEV }}
IKS_DEPLOYMENT_NAME: ${{ secrets.IKS_DEPLOYMENT_NAME_DEV }}
CONTAINER_NAME: ${{ secrets.CONTAINER_NAME_DEV }}
IMAGE_NAME: ${{ secrets.IMAGE_NAME_DEV }}
jobs:
setup-build-publish-deploy-dev:
name: Setup, Build, Publish, and Deploy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
# Turnstyle ensures that this job only runs one at a time in this repository
- name: Turnstyle
uses: softprops/turnstyle@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: call-for-code/build-push-deploy@main
with:
cloud-api-key: $IBM_CLOUD_API_KEY
cloud-region: $IBM_CLOUD_REGION
icr-region: $ICR_REGION
cloud-resource-group: $IBM_CLOUD_RESOURCE_GROUP
deployment-name: $IKS_DEPLOYMENT_NAME
container-name: rulesdecision
github-sha: $GITHUB_SHA
icr-namespace: $ICR_NAMESPACE
image-name: rulesdecision
k8s-cluster-name: $IKS_CLUSTER
k8s-cluster-namespace: $K8S_CLUSTER_NAMESPACE
registry-hostname: $ICR_REGISTRY_HOSTNAME
working-directory: "."