Skip to content

Update the introduction #3

Update the introduction

Update the introduction #3

name: Build and Push Docker Image
on:
push:
branches:
- main
jobs:
build-and-push:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
# Ensure Compose v2.39.3+ is available (includes bug fixes for publishing)
# Can remove this action once default runners include it
- name: Set up Docker Compose
uses: docker/setup-compose-action@v1
with:
version: v2.39.3
- name: Log in to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Publish Compose file
run: |
docker compose -f oci://dockersamples/labspace -f .labspace/compose.override.yaml publish $DOCKERHUB_USERNAME/labspace-container-supported-development --with-env -y
env:
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}