File tree Expand file tree Collapse file tree 6 files changed +96
-263
lines changed Expand file tree Collapse file tree 6 files changed +96
-263
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ name : Pin to ipfs cluster and nodes
2+ description : Upload build to ipfs node
3+ inputs :
4+ BUILD_PATH :
5+ description : path to the build directory
6+ required : true
7+ PINATA_HASH :
8+ description : ' '
9+ required : true
10+ IPFS_SERVER_PORT :
11+ description : ' '
12+ required : true
13+ IPFS_SERVER :
14+ description : ' '
15+ required : true
16+ IPFS_SERVER_KEY :
17+ description : ' '
18+ required : true
19+
20+ runs :
21+ using : ' composite'
22+ steps :
23+ - name : Prepare env and Compress build on IPFS servers
24+ id : ipfs-prepare
25+ continue-on-error : false
26+ shell : bash
27+ run : |
28+ tar -czf app.tar.gz './${{ inputs.BUILD_PATH }}'
29+ rm -rf ./key
30+ echo -n "${{ inputs.IPFS_SERVER_KEY }}" | base64 -d >> ./key && chmod 400 ./key
31+
32+ - name : Upload build to IPFS Primary Server
33+ id : ipfs-scp-primary
34+ continue-on-error : false
35+ shell : bash
36+ run : |
37+ scp -o StrictHostKeyChecking=no \
38+ -i ./key \
39+ -P \${{ inputs.IPFS_SERVER_PORT }} app.tar.gz ipfs@\${{ inputs.IPFS_SERVER }}:.
40+ ssh -o StrictHostKeyChecking=no \
41+ -p \${{ inputs.IPFS_SERVER_PORT }} \
42+ -i ./key ipfs@\${{ inputs.IPFS_SERVER }} "tar zxf app.tar.gz && ipfs add -rQ --cid-version=1 ./${{ inputs.BUILD_PATH }}/"
43+
44+ - name : Clean build and tmp directory on Servers
45+ continue-on-error : false
46+ id : ipfs-clean
47+ shell : bash
48+ run : |
49+ ssh -o StrictHostKeyChecking=no \
50+ -p \${{ inputs.IPFS_SERVER_PORT }} \
51+ -i ./key ipfs@\${{ inputs.IPFS_SERVER }} "rm -rf ./${{ inputs.BUILD_PATH }}/ app.tar.gz"
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -127,11 +127,8 @@ jobs:
127127
128128 - name : Pin to primary IPFS server
129129 id : ipfs-primary
130- uses : ./.github/actions/dev- ipfs-pin
130+ uses : ./.github/actions/ipfs-pin
131131 with :
132- GCP_SA_KEY : ' ${{ secrets.GCP_SA_KEY }}'
133- GKE_CLUSTER : ' ${{ secrets.GKE_CLUSTER }}'
134- GKE_CLUSTER_REGION : ' ${{ secrets.GKE_CLUSTER_REGION }}'
135132 IPFS_SERVER_PORT : ' ${{ secrets.IPFS_PRIMARY_SERVER_PORT }}'
136133 IPFS_SERVER : ' ${{ secrets.IPFS_PRIMARY_SERVER }}'
137134 IPFS_SERVER_KEY : ' ${{ secrets.IPFS_PRIMARY_SERVER_KEY }}'
Original file line number Diff line number Diff line change @@ -138,11 +138,8 @@ jobs:
138138
139139 - name : Pin to primary IPFS server
140140 id : ipfs-primary
141- uses : ./.github/actions/dev- ipfs-pin
141+ uses : ./.github/actions/ipfs-pin
142142 with :
143- GCP_SA_KEY : ' ${{ secrets.GCP_SA_KEY }}'
144- GKE_CLUSTER : ' ${{ secrets.GKE_CLUSTER }}'
145- GKE_CLUSTER_REGION : ' ${{ secrets.GKE_CLUSTER_REGION }}'
146143 IPFS_SERVER_PORT : ' ${{ secrets.IPFS_PRIMARY_SERVER_PORT }}'
147144 IPFS_SERVER : ' ${{ secrets.IPFS_PRIMARY_SERVER }}'
148145 IPFS_SERVER_KEY : ' ${{ secrets.IPFS_PRIMARY_SERVER_KEY }}'
You can’t perform that action at this time.
0 commit comments