Skip to content

Commit 4d94e19

Browse files
authored
chore: use common ipfs/*-actions in sync-release-assets (#8609)
1 parent da35610 commit 4d94e19

File tree

1 file changed

+3
-31
lines changed

1 file changed

+3
-31
lines changed

.github/workflows/sync-release-assets.yml

Lines changed: 3 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -13,38 +13,10 @@ jobs:
1313
sync-github-and-dist-ipfs-io:
1414
runs-on: "ubuntu-latest"
1515
steps:
16-
- name: Setup go
17-
uses: actions/setup-go@v2
16+
- uses: ipfs/download-ipfs-distribution-action@v1
17+
- uses: ipfs/start-ipfs-daemon-action@v1
1818
with:
19-
go-version: '1.16'
20-
- uses: actions/cache@v2
21-
with:
22-
path: |
23-
~/.cache/go-build
24-
~/go/pkg/mod
25-
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
26-
restore-keys: |
27-
${{ runner.os }}-go-
28-
- name: Build go-ipfs binary
29-
run: go install github.com/ipfs/go-ipfs/cmd/ipfs@latest
30-
- name: Initialize go-ipfs and start daemon
31-
run: |
32-
sudo sysctl -w net.core.rmem_max=2500000
33-
ipfs init --profile flatfs,server
34-
ipfs daemon --enable-gc=false &
35-
while (! ipfs id --api "/ip4/127.0.0.1/tcp/5001"); do sleep 1; done
36-
- name: Wait for go-ipfs to be ready
37-
shell: pwsh
38-
run: |
39-
for ($i = 0; $i -lt 10; $i++) {
40-
$addrs = ipfs id | jq .Addresses;
41-
if ($addrs -eq "null") {
42-
sleep 1
43-
} else {
44-
echo "Successfully started the daemon"
45-
exit 0
46-
}
47-
}
19+
args: --init --init-profile=flatfs,server --enable-gc=false
4820
- uses: actions/setup-node@v2
4921
with:
5022
node-version: 14

0 commit comments

Comments
 (0)