-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
GitHub Actions: instalar docker no MacOS-10.
- Loading branch information
Showing
1 changed file
with
70 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
name: Generate Tested Images | ||
|
||
on: | ||
push: | ||
branches: [ "docker-macos" ] | ||
|
||
env: | ||
IMAGE_TAG: gh-${{github.run_number}} | ||
|
||
|
||
jobs: | ||
|
||
publish-macos: | ||
runs-on: macOS-latest | ||
|
||
steps: | ||
- name: Download logs-transparentes source | ||
uses: actions/checkout@v4 | ||
with: | ||
repository: 'larc-logs-transparentes/logs-transparentes' | ||
path: 'logs-transparentes' | ||
|
||
- name: Install Docker | ||
run: | | ||
#brew install colima | ||
#brew services start colima | ||
brew install --cask docker | ||
#brew services restart colima | ||
# For testcontainers to find the Colima socket | ||
# https://github.com/abiosoft/colima/blob/main/docs/FAQ.md#cannot-connect-to-the-docker-daemon-at-unixvarrundockersock-is-the-docker-daemon-running | ||
#sudo ln -sf $HOME/.colima/default/docker.sock /var/run/docker.sock | ||
#docker context use colima | ||
- name: Docker MacOS Image - BU Service | ||
run: | | ||
cd logs-transparentes/backend/bu_service | ||
docker build . --file Dockerfile --tag ghcr.io/larc-logs-transparentes/bu-service:${{env.IMAGE_TAG}} | ||
- name: Docker MacOS Image - Backend Public | ||
run: | | ||
cd logs-transparentes/backend/public | ||
docker build . --file Dockerfile --tag ghcr.io/larc-logs-transparentes/back-pub:${{env.IMAGE_TAG}} | ||
- name: Docker MacOS Image - Frontend | ||
run: | | ||
cd logs-transparentes/frontend_new | ||
docker build . --file Dockerfile --tag ghcr.io/larc-logs-transparentes/frontend:${{env.IMAGE_TAG}} | ||
- name: Docker MacOS Image - TL Manager | ||
run: | | ||
cd logs-transparentes/tlmanager | ||
docker build . --file Dockerfile --tag ghcr.io/larc-logs-transparentes/tlmanager:${{env.IMAGE_TAG}} | ||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Publish MacOS images to ghcr.io | ||
run: | | ||
docker tag ghcr.io/larc-logs-transparentes/bu-service:${{env.IMAGE_TAG}} ghcr.io/larc-logs-transparentes/bu-service:latest | ||
docker push --all-tags ghcr.io/larc-logs-transparentes/bu-service | ||
docker tag ghcr.io/larc-logs-transparentes/back-pub:${{env.IMAGE_TAG}} ghcr.io/larc-logs-transparentes/back-pub:latest | ||
docker push --all-tags ghcr.io/larc-logs-transparentes/back-pub | ||
docker tag ghcr.io/larc-logs-transparentes/frontend:${{env.IMAGE_TAG}} ghcr.io/larc-logs-transparentes/frontend:latest | ||
docker push --all-tags ghcr.io/larc-logs-transparentes/frontend | ||
docker tag ghcr.io/larc-logs-transparentes/tlmanager:${{env.IMAGE_TAG}} ghcr.io/larc-logs-transparentes/tlmanager:latest | ||
docker push --all-tags ghcr.io/larc-logs-transparentes/tlmanager |