Giter Site home page Giter Site logo

cf-push's Introduction

cf push Github Action

This is a work in progress.

How to use

Create a github action that will listen to a new deployment and then push your cf app

name: Deploy to Cloud Foundry
on: push
    
jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v2
      - name : CF PUSH
        uses: jhunt/cf-push@main
        with:
          api:      ${{ secrets.CF_API }}
          org:      ${{ secrets.CF_ORG }}
          space:    ${{ secrets.CF_SPACE }}
          username: ${{ secrets.CF_USERNAME }}
          password: ${{ secrets.CF_PASSWORD }}
          manifest: manifest.yml
          validate: true          # set to false if you don't want to validate ssl

Further Options

By passing the appdir parameter you can define what directory should be used for your CF APP. This can be usefull if you have multiple cf apps in one repository.

If you're not sure about the used directoy that is created in the docker container you can make use of the debug parameter to list all directories in the output of the actions log

name: Deploy to Cloud Foundry
on:
  push:
    paths:
    - 'PATH/TO/YOUR/CF_APP/**'
    
jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v2
      - name : CF PUSH
        uses: jhunt/cf-push@main
        with:
          appdir:   './PATH/TO/YOUR/CF_APP'       # use the appdir option to select a specif folder where the cf app is stored
          api:      ${{ secrets.CF_API }}
          org:      ${{ secrets.CF_ORG }}
          space:    ${{ secrets.CF_SPACE }}
          username: ${{ secrets.CF_USERNAME }}
          password: ${{ secrets.CF_PASSWORD }}
          manifest: manifest.yml
          validate: true          

cf-push's People

Contributors

jhunt avatar rangulvers avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

cf-push's Issues

Configure CF Push for subfolder

Hi jhunt,

maybe I missed it in reading the GH Action docs but I want to use your cf-push workflow to only push a specify sub-folder in a repo. Is this possible?

The workflow would be to list to changes to a specific folder and then push the cf app in this folder. This way I can have multiple CF apps in in repo for learning reasons

Thanks

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.