Actions are individual tasks that you can combine to create jobs and customize your workflow. You can create your own actions, and use and customize actions shared by the GitHub community.
https://github.com/features/actions
Continuous integration (CI) is a software practice that requires frequently committing code to a shared repository.
When you commit code to your repository, you can continuously build and test the code to make sure that the commit doesn't introduce errors. Your tests can include code linters (which check style formatting), security checks, code coverage, functional tests, and other custom checks.
Building and testing your code requires a server. You can build and test updates locally before pushing code to a repository, or you can use a CI server that checks for new code commits in a repository.
GitHub offers CI workflow templates for a variety of languages and frameworks.
Browse the complete list of CI workflow templates offered by GitHub in the actions/starter-workflows repository.
Continuous deployment is a strategy for software releases wherein any code commit that passes the automated testing phase is automatically released into the production environment, making changes that are visible to the software's users.
- Install Heroku CLI
- Login to Heroku CLI session:
heroku login - Create new Heroku App:
heroku create - Generate Authentication Token:
heroku authorizations:create - 'Deploy to Heroku' Action:
- name: Deploy to Heroku
env:
HEROKU_API_TOKEN: ${{ secrets.HEROKU_API_TOKEN }}
HEROKU_APP_NAME: ${{ secrets.HEROKU_APP_NAME }}
if: github.ref == 'refs/heads/master' && job.status == 'success'
run: |
git remote add heroku https://heroku:[email protected]/$HEROKU_APP_NAME.git
git push heroku HEAD:master -f
