Skip to content

cy.yml config script inital build #4

cy.yml config script inital build

cy.yml config script inital build #4

Workflow file for this run

name: Docker Image CI
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
jobs:
build_and_push:
name: 'Build and Push'
runs-on: ubuntu-latest
steps:
- name: Build the Docker image
uses: actions/checkout@v4
# run: docker build . --file Dockerfile --tag my-image-name:$(date +%s)
- name: Generate sha
id: generate_sha
run: |
SHA=$(echo $GITHUB_SHA | head -c7)
echo "sha=$SHA" >> $GITHUB_OUTPUT
- name: Build docker image
run: |
docker build -t rogeriojr/projeto-nlw-node-fastify:${{ steps.generate_sha.outputs.sha }} .