Giter VIP home page Giter VIP logo

serenity-workflow-dev's Introduction

Serenity Workflows

Refactor in progress...

Please come back later :)

About

Serenity workflows aim to provide easy to use, understand and modify reusable github actions workflows for common ci/cd use cases.

  • Workflows DO NOT use marketplace actions or any dependencies except for github default actions.
  • Workflows are given as local files for ease-of-modification and adaptation to your needs.

Known Issues

  • Hiding the SSH key log output with add-mask breaks the _deploy-application.scalingo.reusable workflow.

Table des matières

Prerequisites

⚠️ for a workflow to appear in your available workflows ({ YOUR_REPOSITORY_URL }/actions) a file with the same workflow name must be present on your default branch (usually master / main).

Workflow files contents are however branch dependent (so you can edit a workflow file and try it on a feature branch).

Installation

  • Copy the workflows files in your .github/worflows project folder.

  • Commit / Push / Merge to your default (main / master) branch.

  • Setup a deployer (Clevercloud / Scalingo ...)

  • Fill the necessary env variables in a use case and run it.

Utilisation

There are several types of workflow files :

Setup

The setup files (*.setup.yml) are aimed to configure a deployer for the project.

They are run manually through the github action interface.

Reusable workflows

The reusable workflows (.reusable.yml) are single responsibility building blocs that provide a service. They are usually called by use-case workflows with inputs and may return several outputs

Available now:

Generic
  • Cache dependencies using Yarn lockfile (nodes modules)
  • Build application bundle
  • Enumerate branches that follow a 'feature/*' name pattern
  • Validation (run 'lint' and 'test' package.json scripts)
Clevercloud specific
  • Create/Deploy a node application
  • Create/Deploy a static application
  • Destroy a deployed application
Scalingo specific
  • Create/Deploy a node application
  • Create a feature application with a copy of the database of a reference application
Deployment Notification hooks
  • Discord
  • Mattermost

Use-Cases

Use-case workflows (*.use-case.yml) are used to provide complex scenarios.

They can be called by events (eg on branch push or merge) or event manually

Available as examples:

  • Deploy an application on feature branch push (dep | build & validation | deploy | notify) dac_feature_branch_deploy.png

  • On feature branch deletion / merge delete the associated deployed application.

  • Start / Stop the demo instances according to team schedule (uncomment the 'schedule' to activate)

Available Deployers

Clevercloud

Prerequisites
  • Have a clevercloud account
  • Clevercloud reusable workflows (files with the pattern _*.clevercloud.reusable.yml) must be in your default branch .github/workflows folder.
tl;dr

Set up the

  • CLEVER_TOKEN
  • CLEVER_SECRET
  • (Organisation) CLEVER_ORG_ID

repository variables.

Step-by-step setup

Scalingo

Step-by-step setup Postgresql addon workflow

Contribution

Contributions are welcome ! Just submit a pull request with the files following the naming convention.

Documentation

GitHub Actions documentation

Troubleshooting, tips and tricks

I cannot set my workflow env variables as reusable a workflow input

Licence

Voir le fichier LICENSE du dépôt.

serenity-workflow-dev's People

Contributors

romain-cambonie avatar

Stargazers

 avatar Joseph Garrone avatar Marc Gavanier avatar

Watchers

 avatar Swann avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.