Skip to content

Commit

Permalink
CI: add github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
djbe committed Apr 22, 2024
1 parent e948e8a commit 1266334
Show file tree
Hide file tree
Showing 3 changed files with 63 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/auto-deploy-to-development.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Auto-deploy to development

on: # yamllint disable-line rule:truthy
push:
branches: ['main']
workflow_dispatch:

jobs:
build-and-deploy:
uses: wisemen-digital/devops-github-actions/.github/workflows/workflow-build-and-deploy-scaleway.yml@main
with:
environment: development
scaleway-container-registry: ${{ vars.CONTAINER_REGISTRY_ENDPOINT }}
scaleway-organization-id: ${{ vars.SCALEWAY_ORGANIZATION_ID }}
scaleway-project-id: ${{ vars.SCALEWAY_PROJECT_ID }}
scaleway-region: ${{ vars.SCALEWAY_REGION }}
scaleway-cluster-id: ${{ vars.K8S_CLUSTER_ID }}
cluster-deployments: ${{ vars.K8S_DEPLOYMENTS }}
secrets: inherit
28 changes: 28 additions & 0 deletions .github/workflows/promote-to-enviroment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
name: Promote to enviroment

on: # yamllint disable-line rule:truthy
workflow_dispatch:
inputs:
environment:
description: Target environment to deploy TO
type: environment
required: true
source-tag:
description: Source tag (defaults to previous environment)
type: string
required: false

jobs:
promote-to-env:
uses: wisemen-digital/devops-github-actions/.github/workflows/workflow-promote-to-environment-scaleway.yml@main
with:
environment-source: ${{ inputs.source-tag }}
environment-target: ${{ inputs.environment }}
scaleway-container-registry: ${{ vars.CONTAINER_REGISTRY_ENDPOINT }}
scaleway-organization-id: ${{ vars.SCALEWAY_ORGANIZATION_ID }}
scaleway-project-id: ${{ vars.SCALEWAY_PROJECT_ID }}
scaleway-region: ${{ vars.SCALEWAY_REGION }}
scaleway-cluster-id: ${{ vars.K8S_CLUSTER_ID }}
cluster-deployments: ${{ vars.K8S_DEPLOYMENTS }}
secrets: inherit
15 changes: 15 additions & 0 deletions .github/workflows/pullrequest-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
name: PR Check

on: # yamllint disable-line rule:truthy
pull_request:
types: [opened, synchronize, reopened, ready_for_review]
branches:
- main

jobs:
lint-build-test:
uses: wisemen-digital/devops-github-actions/.github/workflows/laravel-build-and-test.yml@main
if: github.event.pull_request.draft == false
with:
php-version: '8.3'

0 comments on commit 1266334

Please sign in to comment.