Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump pipeline from 1.10.0 to 1.10.2 #310

Merged
merged 1 commit into from
Jul 9, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/pipeline-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.10.0
1.10.2
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
name: Create Action alibaba-dragonwell-dependency
"on":
pull_request:
paths:
- actions/*
- actions/alibaba-dragonwell-dependency/*
push:
branches:
- main
paths:
- actions/*
- actions/alibaba-dragonwell-dependency/*
release:
types:
- published
jobs:
create-action:
name: Create Action
runs-on:
- ubuntu-latest
steps:
- if: ${{ github.event_name != 'pull_request' || ! github.event.pull_request.head.repo.fork }}
name: Docker login ghcr.io
uses: docker/login-action@v1
with:
password: ${{ secrets.JAVA_GITHUB_TOKEN }}
registry: ghcr.io
username: ${{ secrets.JAVA_GITHUB_USERNAME }}
- uses: actions/checkout@v2
- id: version
name: Compute Version
run: |
#!/usr/bin/env bash

set -euo pipefail

if [[ ${GITHUB_REF} =~ refs/tags/v([0-9]+\.[0-9]+\.[0-9]+) ]]; then
VERSION=${BASH_REMATCH[1]}
elif [[ ${GITHUB_REF} =~ refs/heads/(.+) ]]; then
VERSION=${BASH_REMATCH[1]}
else
VERSION=$(git rev-parse --short HEAD)
fi

echo "::set-output name=version::${VERSION}"
echo "Selected ${VERSION} from
* ref: ${GITHUB_REF}
* sha: ${GITHUB_SHA}
"
- 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: alibaba-dragonwell-dependency
TARGET: ghcr.io/paketo-buildpacks/actions/alibaba-dragonwell-dependency
VERSION: ${{ steps.version.outputs.version }}
75 changes: 75 additions & 0 deletions .github/workflows/create-action-foojay-dependency.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
name: Create Action foojay-dependency
"on":
pull_request:
paths:
- actions/*
- actions/foojay-dependency/*
push:
branches:
- main
paths:
- actions/*
- actions/foojay-dependency/*
release:
types:
- published
jobs:
create-action:
name: Create Action
runs-on:
- ubuntu-latest
steps:
- if: ${{ github.event_name != 'pull_request' || ! github.event.pull_request.head.repo.fork }}
name: Docker login ghcr.io
uses: docker/login-action@v1
with:
password: ${{ secrets.JAVA_GITHUB_TOKEN }}
registry: ghcr.io
username: ${{ secrets.JAVA_GITHUB_USERNAME }}
- uses: actions/checkout@v2
- id: version
name: Compute Version
run: |
#!/usr/bin/env bash

set -euo pipefail

if [[ ${GITHUB_REF} =~ refs/tags/v([0-9]+\.[0-9]+\.[0-9]+) ]]; then
VERSION=${BASH_REMATCH[1]}
elif [[ ${GITHUB_REF} =~ refs/heads/(.+) ]]; then
VERSION=${BASH_REMATCH[1]}
else
VERSION=$(git rev-parse --short HEAD)
fi

echo "::set-output name=version::${VERSION}"
echo "Selected ${VERSION} from
* ref: ${GITHUB_REF}
* sha: ${GITHUB_SHA}
"
- 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: foojay-dependency
TARGET: ghcr.io/paketo-buildpacks/actions/foojay-dependency
VERSION: ${{ steps.version.outputs.version }}