Skip to content

Commit

Permalink
Initial stack implementation
Browse files Browse the repository at this point in the history
Based on the tiny variant: https://github.com/paketo-buildpacks/jammy-tiny-stack/tree/e9a41436b06d3c3fa2960980ea98be36796ab3b6

Changes:
- Renamed
  - search and replace `tiny` with `base`
  - change stack id from `io.buildpacks.stacks.jammy.base` to `io.buildpacks.stacks.jammy` as suggested in paketo-buildpacks#1
- Updated README
- Updated description
- Recreated the `Dockerfile` of the run image based on the build image `Dockerfile`
- Added some packages from bionic base stack
- Updated the integration test (use a simple java app instead of go)

Co-authored-by: Philipp Stehle <[email protected]>
  • Loading branch information
kulhadia and phil9909 committed Jun 22, 2022
1 parent 5621e9e commit dc6d628
Show file tree
Hide file tree
Showing 45 changed files with 6,055 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @paketo-buildpacks/stacks-maintainers
33 changes: 33 additions & 0 deletions .github/labels.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
- name: status/possible-priority
description: This issue is ready to work and should be considered as a potential priority
color: F9D0C4
- name: "release-issue"
description: Automated issue alerting to release workflow failure
color: 941515
- name: status/prioritized
description: This issue has been triaged and resolving it is a priority
color: BFD4F2
- name: status/blocked
description: This issue has been triaged and resolving it is blocked on some other issue
color: 848978
- name: bug
description: Something isn't working
color: d73a4a
- name: enhancement
description: A new feature or request
color: a2eeef
- name: documentation
description: This issue relates to writing documentation
color: D4C5F9
- name: semver:major
description: A change requiring a major version bump
color: 6b230e
- name: semver:minor
description: A change requiring a minor version bump
color: cc6749
- name: semver:patch
description: A change requiring a patch version bump
color: f9d0c4
- name: good first issue
description: A good first issue to get started with
color: d3fc03
69 changes: 69 additions & 0 deletions .github/workflows/approve-bot-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
name: Approve Bot PRs and Enable Auto-Merge

on:
workflow_run:
workflows: ["Test Pull Request"]
types:
- completed

jobs:
download:
name: Download PR Artifact
if: ${{ github.event.workflow_run.event == 'pull_request' && github.event.workflow_run.conclusion == 'success' }}
runs-on: ubuntu-latest
outputs:
pr-author: ${{ steps.pr-data.outputs.author }}
pr-number: ${{ steps.pr-data.outputs.number }}
steps:
- name: 'Download artifact'
uses: paketo-buildpacks/github-config/actions/pull-request/download-artifact@main
with:
name: "event-payload"
repo: ${{ github.repository }}
run_id: ${{ github.event.workflow_run.id }}
workspace: "/github/workspace"
token: ${{ secrets.PAKETO_BOT_GITHUB_TOKEN }}
- id: pr-data
run: |
echo "::set-output name=author::$(jq -r '.pull_request.user.login' < event.json)"
echo "::set-output name=number::$(jq -r '.pull_request.number' < event.json)"
approve:
name: Approve Bot PRs
needs: download
if: ${{ needs.download.outputs.pr-author == 'paketo-bot' || needs.download.outputs.pr-author == 'dependabot[bot]' }}
runs-on: ubuntu-latest
steps:
- name: Check Commit Verification
id: unverified-commits
uses: paketo-buildpacks/github-config/actions/pull-request/check-unverified-commits@main
with:
token: ${{ secrets.PAKETO_BOT_REVIEWER_GITHUB_TOKEN }}
repo: ${{ github.repository }}
number: ${{ needs.download.outputs.pr-number }}

- name: Check for Human Commits
id: human-commits
uses: paketo-buildpacks/github-config/actions/pull-request/check-human-commits@main
with:
token: ${{ secrets.PAKETO_BOT_REVIEWER_GITHUB_TOKEN }}
repo: ${{ github.repository }}
number: ${{ needs.download.outputs.pr-number }}

- name: Checkout
if: steps.human-commits.outputs.human_commits == 'false' && steps.unverified-commits.outputs.unverified_commits == 'false'
uses: actions/checkout@v3

- name: Approve
if: steps.human-commits.outputs.human_commits == 'false' && steps.unverified-commits.outputs.unverified_commits == 'false'
uses: paketo-buildpacks/github-config/actions/pull-request/approve@main
with:
token: ${{ secrets.PAKETO_BOT_REVIEWER_GITHUB_TOKEN }}
number: ${{ needs.download.outputs.pr-number }}

- name: Enable Auto-Merge
if: steps.human-commits.outputs.human_commits == 'false' && steps.unverified-commits.outputs.unverified_commits == 'false'
run: |
gh pr merge ${{ needs.download.outputs.pr-number }} --auto --rebase
env:
GITHUB_TOKEN: ${{ secrets.PAKETO_BOT_GITHUB_TOKEN }}
Loading

0 comments on commit dc6d628

Please sign in to comment.