Skip to content

Commit

Permalink
Add rig-ubuntu-dbi
Browse files Browse the repository at this point in the history
  • Loading branch information
krlmlr committed Oct 6, 2024
1 parent cf12c55 commit 917fef8
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 0 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,47 @@ jobs:
${{ env.REGISTRY }}/${{ env.REPO_NAME }}/${{ matrix.image }}:latest
cache-from: type=registry,ref=${{ env.REGISTRY }}/${{ env.REPO_NAME }}/${{ matrix.image }}:latest
cache-to: type=inline

build-and-push-image-2:
needs: build-and-push-image
runs-on: ubuntu-latest
# Sets the permissions granted to the `GITHUB_TOKEN` for the actions in this job.
permissions:
contents: read
packages: write
id-token: write
#
strategy:
matrix:
image:
- rig-ubuntu-dbi
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Log in to the Container registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract metadata (tags, labels) for Docker
env:
IMAGE: ${{ matrix.image }}/Dockerfile
id: meta
run: |
echo "tag=$(grep FROM $IMAGE | cut -d: -f2)" >> "$GITHUB_OUTPUT"
# setup buildx is needed to use cache
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build and push Docker image
id: push
uses: docker/build-push-action@v6
with:
context: .
file: ${{ matrix.image }}/Dockerfile
push: ${{ github.ref == 'refs/heads/main' }}
tags: |
${{ env.REGISTRY }}/${{ env.REPO_NAME }}/${{ matrix.image }}:${{ steps.meta.outputs.tag }}
${{ env.REGISTRY }}/${{ env.REPO_NAME }}/${{ matrix.image }}:latest
cache-from: type=registry,ref=${{ env.REGISTRY }}/${{ env.REPO_NAME }}/${{ matrix.image }}:latest
cache-to: type=inline
7 changes: 7 additions & 0 deletions rig-ubuntu-dbi/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
FROM ghcr.io/cynkra/docker-images/rig-ubuntu:main

RUN apt-get install -y gnupg lsb-release time

RUN R -q -e 'pak::pak(c("DBI", "RMariaDB", "RPostgres", "RSQLite", "dm", "duckdb", "odbc", "adbi", "cpp11", "devtools", "decor", "plogr", "reprex"), dependencies = TRUE)'

RUN R-devel -q -e 'pak::pak(c("DBI", "RMariaDB", "RPostgres", "RSQLite", "dm", "duckdb", "odbc", "adbi", "cpp11", "devtools", "decor", "plogr", "reprex"), dependencies = TRUE)'

0 comments on commit 917fef8

Please sign in to comment.