Skip to content

Commit

Permalink
initia
Browse files Browse the repository at this point in the history
  • Loading branch information
nicko170 committed Apr 29, 2024
0 parents commit a149ffd
Show file tree
Hide file tree
Showing 7 changed files with 115 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Build Container

on:
workflow_dispatch:
release:
types: [ published ]


permissions:
contents: read
packages: write
actions: write

concurrency:
group: build-base-${{ github.ref }}
cancel-in-progress: true

env:
REGISTRY_IMAGE: ghcr.io/iaa-inc/gh-runner

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Extract metadata for the Docker image
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY_IMAGE }}

- name: Build and push by digest
id: build
uses: docker/build-push-action@v5
with:
context: .
labels: ${{ steps.meta.outputs.labels }}
tags: ${{ steps.meta.outputs.tags }}
push: true
27 changes: 27 additions & 0 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
on:
push:
branches:
- main

name: release-please

concurrency:
group: release-please-${{ github.ref }}
cancel-in-progress: true

jobs:
release-please:
runs-on: ubuntu-latest
steps:
- name: Generate Token
uses: tibdex/github-app-token@3beb63f4bd073e61482598c45c71c1019b59b73a # v2.1.0
id: generate-token
with:
app_id: ${{ secrets.BOT_APP_ID }}
private_key: ${{ secrets.BOT_APP_PRIVATE_KEY }}

- uses: google-github-actions/release-please-action@v3
with:
token: "${{ steps.generate-token.outputs.token }}"
package-name: IAA GH - Runner
release-type: php
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/.idea/
Empty file added .release-please-manifest.json
Empty file.
Empty file added CHANGELOG.md
Empty file.
27 changes: 27 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
FROM ghcr.io/actions/runner:latest

USER root

# Install Python & other dependencies
RUN apt-get update && apt-get install -y python3 python3-pip apt-transport-https \
ca-certificates curl file make jq unzip autoconf automake gcc g++ gnupg

# Install NodeJS, and Yarn
RUN curl -sL https://deb.nodesource.com/setup_20.x | bash - && \
apt-get install -y nodejs && \
npm install -g yarn

RUN add-apt-repository ppa:ondrej/php

# Install PHP & Extensions
# ctype, curl, fileinfo, json, mbstring, mysqli, openssl, pdo, pgsql, redis, tokenizer, xml, zip, bcmath, soap, php-gd, pdo_sqlite
RUN apt install php8.3 php8.3-ctype php8.3-curl php8.3-fileinfo php8.3-json \
php8.3-mbstring php8.3-mysqli php8.3-openssl php8.3-pdo php8.3-pgsql \
php8.3-redis php8.3-tokenizer php8.3-xml php8.3-zip php8.3-bcmath \
php8.3-soap php8.3-gd php8.3-pdo_sqlite php8.3-sqlite3 php8.3-mysql \
php8.3-intl php8.3-imagick php8.3-xmlrpc php8.3-ldap php8.3-xml

# Install Composer
COPY --from=composer:latest /usr/bin/composer /usr/bin/composer

USER runner
13 changes: 13 additions & 0 deletions release-please-config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"packages": {
".": {
"changelog-path": "CHANGELOG.md",
"release-type": "php",
"bump-minor-pre-major": false,
"bump-patch-for-minor-pre-major": false,
"draft": false,
"prerelease": false
}
},
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json"
}

0 comments on commit a149ffd

Please sign in to comment.