Skip to content

Commit

Permalink
added workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
antonkulaga committed Oct 21, 2024
1 parent 8b436fa commit 7e179b8
Show file tree
Hide file tree
Showing 2 changed files with 86 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/build-biosandbox.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: build and push biosandbox

on:
push:
branches: [ main ]
paths:
- 'just_agents_sandbox/containers/biosandbox/**'

env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}/biosandbox

jobs:
build-and-push:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write

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
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}

- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: ./just_agents_sandbox/containers/biosandbox
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
43 changes: 43 additions & 0 deletions .github/workflows/build-sandbox.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: build and push sandbox

on:
push:
branches: [ main ]
paths:
- 'just_agents_sandbox/containers/sandbox/**'

env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}/sandbox

jobs:
build-and-push:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write

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
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}

- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: ./just_agents_sandbox/containers/sandbox
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

0 comments on commit 7e179b8

Please sign in to comment.