Coder Social home page Coder Social logo

lo236816 / clean-self-hosted-runner Goto Github PK

View Code? Open in Web Editor NEW

This project forked from eviden-actions/clean-self-hosted-runner

0.0 0.0 0.0 1.85 MB

GitHub Actions to clean the working directory on self hosted runners

License: MIT License

Shell 85.01% JavaScript 14.99%

clean-self-hosted-runner's Introduction

clean-self-hosted-runner

GitHub Actions to clean the working directory on self hosted runners

Release

Per the official documentation, self-hosted runners don't need to have a clean instance for every job execution. Your job might however need a clean working directory for every execution.

The goal of this action is to clean the working directory at the beginning or the end of each job.

Usage

steps:
  - uses: eviden-actions/clean-self-hosted-runner@v1

Options

To disable the cleanup job (e.g. for debugging purpose), set the environment variable DISABLE_RUNNER_CLEANUP to true

Example

This is an example of a simple NPM build workflow that will clean the working directory after each execution.

name: My Workflow

on:
  pull_request:
    types: [opened, synchronize, reopened]

jobs:
  build:
    runs-on: self-hosted

    steps:
      - uses: actions/checkout@v4
      - uses: actions/setup-node@v3
      - run: npm ci
      - run: npm run build
      - uses: eviden-actions/clean-self-hosted-runner@v1
        if: ${{ always() }} # Run even if previous steps in the job fail or are canceled

clean-self-hosted-runner's People

Contributors

dependabot[bot] avatar th3s4mur41 avatar semantic-release-bot 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.