Skip to content

Commit

Permalink
🔀 Merge pull request #31 from likesistemas/feature/NFE-180
Browse files Browse the repository at this point in the history
✨ [NFE-180] Adicionar Sentry Dsn nas variáveis de ambiente
  • Loading branch information
ricardoapaes committed Nov 13, 2023
2 parents 03b5777 + 0deb9d8 commit aca6334
Show file tree
Hide file tree
Showing 4 changed files with 55 additions and 122 deletions.
69 changes: 15 additions & 54 deletions .github/workflows/docker-publish-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
test:
strategy:
matrix:
PHP: [56, 73, 74, 80, 81]
PHP: [73, 74, 80, 81]

runs-on: ubuntu-latest

Expand Down Expand Up @@ -107,6 +107,10 @@ jobs:
push:
needs: test

strategy:
matrix:
PHP: [73, 74, 80, 81]

runs-on: ubuntu-latest
if: github.event_name == 'push'

Expand All @@ -122,63 +126,20 @@ jobs:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Login to GitHub Container Registry
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.CR_PAT }}

- name: PHP 5.6 -> Build and push
uses: docker/build-push-action@v2
with:
context: .
build-args: |
VERSAO_PHP=likesistemas/php-dev:56
push: true
tags: |
likesistemas/sistema-core-dev:56
likesistemas/sistema-core-dev:5.6
ghcr.io/likesistemas/sistema-core-dev:56
ghcr.io/likesistemas/sistema-core-dev:5.6
- name: PHP 7.3 -> Build and push
uses: docker/build-push-action@v2
with:
context: .
build-args: |
VERSAO_PHP=likesistemas/php-dev:73
push: true
tags: |
likesistemas/sistema-core-dev:latest
likesistemas/sistema-core-dev:73
likesistemas/sistema-core-dev:7.3
ghcr.io/likesistemas/sistema-core-dev:latest
ghcr.io/likesistemas/sistema-core-dev:73
ghcr.io/likesistemas/sistema-core-dev:7.3
- name: PHP 7.4 -> Build and push
uses: docker/build-push-action@v2
with:
context: .
build-args: |
VERSAO_PHP=likesistemas/php-dev:74
push: true
tags: |
likesistemas/sistema-core-dev:74
likesistemas/sistema-core-dev:7.4
ghcr.io/likesistemas/sistema-core-dev:74
ghcr.io/likesistemas/sistema-core-dev:7.4
# - name: Login to GitHub Container Registry
# uses: docker/login-action@v1
# with:
# registry: ghcr.io
# username: ${{ github.repository_owner }}
# password: ${{ secrets.CR_PAT }}

- name: PHP 8.0 -> Build and push
- name: Build and push
uses: docker/build-push-action@v2
with:
context: .
build-args: |
VERSAO_PHP=likesistemas/php-dev:80
VERSAO_PHP=likesistemas/php-dev:${{ matrix.PHP }}
push: true
tags: |
likesistemas/sistema-core-dev:80
likesistemas/sistema-core-dev:8.0
ghcr.io/likesistemas/sistema-core-dev:80
ghcr.io/likesistemas/sistema-core-dev:8.0
likesistemas/sistema-core-dev:${{ matrix.PHP }}
# ghcr.io/likesistemas/sistema-core-dev:${{ matrix.PHP }}
82 changes: 15 additions & 67 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
test:
strategy:
matrix:
PHP: [56, 73, 74, 80, 81]
PHP: [73, 74, 80, 81]

runs-on: ubuntu-latest

Expand Down Expand Up @@ -148,6 +148,10 @@ jobs:
push:
needs: test

strategy:
matrix:
PHP: [73, 74, 80, 81]

runs-on: ubuntu-latest
if: github.event_name == 'push'

Expand All @@ -163,76 +167,20 @@ jobs:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Login to GitHub Container Registry
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.CR_PAT }}

- name: PHP 5.6 -> Build and push
uses: docker/build-push-action@v2
with:
context: .
build-args: |
VERSAO_PHP=likesistemas/php:56
push: true
tags: |
likesistemas/sistema-core:56
likesistemas/sistema-core:5.6
ghcr.io/likesistemas/sistema-core:56
ghcr.io/likesistemas/sistema-core:5.6
# - name: Login to GitHub Container Registry
# uses: docker/login-action@v1
# with:
# registry: ghcr.io
# username: ${{ github.repository_owner }}
# password: ${{ secrets.CR_PAT }}

- name: PHP 7.3 -> Build and push
uses: docker/build-push-action@v2
with:
context: .
build-args: |
VERSAO_PHP=likesistemas/php:73
push: true
tags: |
likesistemas/sistema-core:latest
likesistemas/sistema-core:73
likesistemas/sistema-core:7.3
ghcr.io/likesistemas/sistema-core:latest
ghcr.io/likesistemas/sistema-core:73
ghcr.io/likesistemas/sistema-core:7.3
- name: PHP 7.4 -> Build and push
uses: docker/build-push-action@v2
with:
context: .
build-args: |
VERSAO_PHP=likesistemas/php:74
push: true
tags: |
likesistemas/sistema-core:74
likesistemas/sistema-core:7.4
ghcr.io/likesistemas/sistema-core:74
ghcr.io/likesistemas/sistema-core:7.4
- name: PHP 8.0 -> Build and push
uses: docker/build-push-action@v2
with:
context: .
build-args: |
VERSAO_PHP=likesistemas/php:80
push: true
tags: |
likesistemas/sistema-core:80
likesistemas/sistema-core:8.0
ghcr.io/likesistemas/sistema-core:80
ghcr.io/likesistemas/sistema-core:8.0
- name: PHP 8.1 -> Build and push
- name: Build and push
uses: docker/build-push-action@v2
with:
context: .
build-args: |
VERSAO_PHP=likesistemas/php:81
VERSAO_PHP=likesistemas/php:${{ matrix.PHP }}
push: true
tags: |
likesistemas/sistema-core:81
likesistemas/sistema-core:8.1
ghcr.io/likesistemas/sistema-core:81
ghcr.io/likesistemas/sistema-core:8.1
likesistemas/sistema-core:${{ matrix.PHP }}
# ghcr.io/likesistemas/sistema-core:${{ matrix.PHP }}
20 changes: 20 additions & 0 deletions docker-compose-82.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
version: '3.5'

services:

app:
command: app create && add-new-config php version 8.2
environment:
- DB_HOST_SLAVE=mysql_slave
- MEMCACHE_HOST=memcache
- MEMCACHE_PORT=11212
- EMAIL_USUARIO=core@likesistemas.com.br
- EMAIL_SENHA=123456
- EMAIL_DE=contato@likesistemas.com.br
- EMAIL_NOME=Ricardo
- AWS_KEY=like123456
- AWS_SECRET=78910

nginx:
environment:
- INDEX_FILE=index.php
6 changes: 5 additions & 1 deletion sh/configure-db-ini
Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,8 @@ fi

if [ -n "$AWS_SECRET" ]; then
crudini --set ${1} aws secret ${AWS_SECRET};
fi
fi

if [ -n "$SENTRY_DSN" ]; then
crudini --set ${1} sentry dsn ${SENTRY_DSN};
fi

0 comments on commit aca6334

Please sign in to comment.