Skip to content

build and publish core images #2

build and publish core images

build and publish core images #2

Workflow file for this run

name: Build Base Images
on:
pull_request:
branches: [main]
workflow_dispatch:
jobs:
build-images:
runs-on: ubuntu-latest
defaults:
run:
working-directory: './images'
steps:
- name: 'Checkout GitHub Action'
uses: actions/checkout@v4
- name: 'Login to GitHub Container Registry'
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{github.actor}}
password: ${{secrets.GITHUB_TOKEN}}
- name: Git SHA
shell: bash
run: |
echo "git_sha=$(git rev-parse --short "$GITHUB_SHA")" >> "$GITHUB_ENV"
- name: 'Build alpine image'
run: |
docker build -t ghcr.io/cfpb/regtech/sbl/alpine:3.18_${{env.git_sha}} -f Dockerfile-alpine .
- name: 'Build python-alpine image'
run: |
docker build -t ghcr.io/cfpb/regtech/sbl/python-alpine:3.12_${{env.git_sha}} -f Dockerfile-python-alpine .
- name: 'Build nginx-alpine image'
run: |
docker build -t ghcr.io/cfpb/regtech/sbl/nginx-alpine:1.27_${{env.git_sha}} -f Dockerfile-nginx-alpine .
- name: 'Build node-js-alpine image'
run: |
docker build -t ghcr.io/cfpb/regtech/sbl/node-js-alpine:3.20_${{env.git_sha}} -f Dockerfile-node-js-alpine .
- name: 'Build python-ubi8 image'
run: |
docker build -t ghcr.io/cfpb/regtech/sbl/python-ubi8:3.12_${{env.git_sha}} -f Dockerfile-python-ubi8 .