-
Notifications
You must be signed in to change notification settings - Fork 5
65 lines (54 loc) · 1.59 KB
/
workflow.yaml
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
name: Process and Release Amnezia Split Tunnel JSON
on:
push:
branches:
- main
pull_request:
branches:
- main
schedule:
- cron: '0 0 * * 0' # Runs at midnight (00:00) every Sunday
workflow_dispatch: # Allows manual triggering from the GitHub interface
jobs:
build-and-release:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
submodules: true # Fetch submodules
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.12'
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install -r NetblockTool/requirements.txt
- name: Run gather.sh
run: |
chmod +x ./gather.sh
./gather.sh
- name: Process CSV files
run: |
python convert_to_amnezia_format.py # Replace with your actual script name
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: amnezia_split_tunnel_hostnames
path: split_tunneling_amnezia.json
- name: Get current date and time
id: date
run: echo "CURRENT_DATE=$(date +'%Y-%m-%d')" >> $GITHUB_ENV
- name: Create Release
id: create_release
uses: ncipollo/release-action@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag: "${{ env.CURRENT_DATE }}"
name: 'Release ${{ env.CURRENT_DATE }}'
artifacts: "./split_tunneling_amnezia.json"
makeLatest: true
replacesArtifacts: true
allowUpdates: true