Skip to content

Commit

Permalink
Merge pull request #1392 from paketo-buildpacks/add-oracle
Browse files Browse the repository at this point in the history
Add action for publishing oracle updater
  • Loading branch information
dmikusa authored Dec 7, 2023
2 parents b28c692 + 796988b commit 03b7beb
Showing 2 changed files with 57 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .github/pipeline-descriptor.yml
Original file line number Diff line number Diff line change
@@ -64,6 +64,8 @@ actions:
target: ghcr.io/paketo-buildpacks/actions/new-relic-dependency
- source: npm-dependency
target: ghcr.io/paketo-buildpacks/actions/npm-dependency
- source: oracle-dependency
target: ghcr.io/paketo-buildpacks/actions/oracle-dependency
- source: overops-dependency
target: ghcr.io/paketo-buildpacks/actions/overops-dependency
- source: paketo-deps-dependency
55 changes: 55 additions & 0 deletions .github/workflows/pb-create-action-oracle-dependency.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Create Action oracle-dependency
"on":
pull_request:
paths:
- actions/*
- actions/oracle-dependency/*
push:
branches:
- main
paths:
- actions/*
- actions/oracle-dependency/*
release:
types:
- published
jobs:
create-action:
name: Create Action
runs-on:
- ubuntu-latest
steps:
- name: Docker login ghcr.io
if: ${{ (github.event_name != 'pull_request' || ! github.event.pull_request.head.repo.fork) && (github.actor != 'dependabot[bot]') }}
uses: docker/login-action@v2
with:
password: ${{ secrets.PAKETO_BOT_GITHUB_TOKEN }}
registry: ghcr.io
username: ${{ secrets.JAVA_GITHUB_USERNAME }}
- uses: actions/checkout@v3
- name: Create Action
run: |
#!/usr/bin/env bash
set -euo pipefail
echo "::group::Building ${TARGET}:${VERSION}"
docker build \
--file actions/Dockerfile \
--build-arg "SOURCE=${SOURCE}" \
--tag "${TARGET}:${VERSION}" \
.
echo "::endgroup::"
if [[ "${PUSH}" == "true" ]]; then
echo "::group::Pushing ${TARGET}:${VERSION}"
docker push "${TARGET}:${VERSION}"
echo "::endgroup::"
else
echo "Skipping push"
fi
env:
PUSH: ${{ github.event_name != 'pull_request' }}
SOURCE: oracle-dependency
TARGET: ghcr.io/paketo-buildpacks/actions/oracle-dependency
VERSION: main

0 comments on commit 03b7beb

Please sign in to comment.