-
Notifications
You must be signed in to change notification settings - Fork 5
39 lines (35 loc) · 1.33 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: UsuarioService-Release
on:
push:
tags:
- 'v*'
pull_request:
types: [closed]
jobs:
generate-release:
runs-on: ubuntu-latest
steps:
- name: Get file name
id: name
run: echo "::set-output name=file_name::fga-eps-mds_2023.2-Dnit-UsuarioService-$(TZ='America/Sao_Paulo' date +'%m-%d-%Y-%H-%M-%S')-${{github.ref_name}}"
- name: Copy repository and download metrics
uses: actions/checkout@v2
- run: wget $METRICS_URL -O ${{ steps.name.outputs.file_name }}.json
env:
METRICS_URL: ${{ secrets.METRICS_URL }}
- name: Uploads file
uses: actions/upload-artifact@v2
with:
name: ${{ steps.name.outputs.file_name }}.json
path: ${{ steps.name.outputs.file_name }}.json
- name: Send metrics to doc repo
uses: dmnemec/[email protected]
env:
API_TOKEN_GITHUB: ${{ secrets.GIT_TOKEN }}
with:
source_file: ${{ steps.name.outputs.file_name }}.json
destination_repo: 'fga-eps-mds/2023.2-Dnit-DOC'
destination_folder: 'analytics-raw-data'
user_email: ${{ secrets.GIT_EMAIL}}
user_name: ${{ secrets.GIT_USER }}
commit_message: Métricas automáticas da release ${{github.ref_name}} - ${{ github.event.repository.name }}