mirror of
https://github.com/Crosstalk-Solutions/project-nomad.git
synced 2026-03-28 03:29:25 +01:00
build: update dockerfile location
This commit is contained in:
parent
97434a6f5f
commit
d0b451e969
27
.github/workflows/docker.yml
vendored
27
.github/workflows/docker.yml
vendored
|
|
@ -9,6 +9,22 @@ on:
|
|||
type: string
|
||||
|
||||
jobs:
|
||||
debug:
|
||||
name: Debugging information
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
- name: List repository root contents
|
||||
run: |
|
||||
echo "Repository root contents:"
|
||||
ls -la
|
||||
echo "Looking for admin directory:"
|
||||
ls -la admin/ || echo "admin directory not found"
|
||||
- name: Print GitHub context
|
||||
run: echo "${{ toJson(github) }}"
|
||||
- name: Print workflow inputs
|
||||
run: echo "${{ toJson(inputs) }}"
|
||||
check_authorization:
|
||||
name: Check authorization to publish new Docker image
|
||||
runs-on: ubuntu-latest
|
||||
|
|
@ -17,13 +33,18 @@ jobs:
|
|||
steps:
|
||||
- name: check-auth
|
||||
id: check-auth
|
||||
run: echo "is_authorized=${{ contains(secrets.DEPLOYMENT_AUTHORIZED_USERS, github.triggering_actor) }}" >> $GITHUB_OUTPUT
|
||||
run: echo "is_authorized=${{ contains(secrets.DEPLOYMENT_AUTHORIZED_USERS, github.triggering_actor) }}" >> $GITHUB_OUTPUT
|
||||
build:
|
||||
name: Build Docker image
|
||||
needs: check_authorization
|
||||
if: needs.check_authorization.outputs.isAuthorized == 'true'
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
contents: read
|
||||
packages: write
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
- name: Log in to GitHub Container Registry
|
||||
uses: docker/login-action@v2
|
||||
with:
|
||||
|
|
@ -31,7 +52,9 @@ jobs:
|
|||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
- name: Build and push
|
||||
uses: docker/build-push-action@v4
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
context: ./admin
|
||||
file: ./admin/Dockerfile
|
||||
push: true
|
||||
tags: ghcr.io/crosstalk-solutions/project-nomad-admin:${{ inputs.version }}
|
||||
Loading…
Reference in New Issue
Block a user