-
Notifications
You must be signed in to change notification settings - Fork 172
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
Showing
3 changed files
with
44 additions
and
48 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 |
---|---|---|
|
@@ -20,28 +20,22 @@ jobs: | |
max-parallel: 1 | ||
name: node.js_${{ matrix.node }}_test | ||
steps: | ||
- name: Check CLOUDFLARE_TUNNEL_ID | ||
id: check_tunnel | ||
run: | | ||
if [[ -n "${{ secrets.CLOUDFLARE_TUNNEL_ID }}" ]]; then | ||
echo "::save-state name=useCfTunnel::true" | ||
else | ||
echo "::save-state name=useCfTunnel::false" | ||
fi | ||
- name: Setup cloudflared | ||
if: steps.check_tunnel.outputs.useCfTunnel == 'true' | ||
uses: AnimMouse/setup-cloudflared@v1 | ||
with: | ||
cloudflare_tunnel_credential: | ||
${{ secrets.CLOUDFLARE_TUNNEL_CREDENTIAL }} | ||
cloudflare_tunnel_configuration: | ||
${{ secrets.CLOUDFLARE_TUNNEL_CONFIGURATION }} | ||
cloudflare_tunnel_id: ${{ secrets.CLOUDFLARE_TUNNEL_ID }} | ||
- uses: actions/checkout@v3 | ||
- name: Setup node | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node }} | ||
- uses: codetalkio/[email protected] | ||
id: expose-tunnel | ||
with: | ||
service: bore.pub | ||
port: 5001 | ||
- name: Accessing the tunnel url | ||
run: | ||
echo "Tunnel has been started at '${{ | ||
steps.expose-tunnel.outputs.tunnel-url }}'" | ||
- name: Accessing the tunnel url | ||
run: echo ${{ steps.expose-tunnel.outputs.tunnel-url }} >> $PROXY_URL | ||
- name: NPM install | ||
run: npm install | ||
- name: Install firebase CLI | ||
|
@@ -57,6 +51,3 @@ jobs: | |
run: npm run test | ||
env: | ||
STRIPE_API_KEY: ${{ secrets.STRIPE_API_KEY }} | ||
- name: Shutdown and view logs of cloudflared | ||
if: always() && steps.check_tunnel.outputs.useCfTunnel == 'true' | ||
uses: AnimMouse/setup-cloudflared/shutdown@v1 |
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
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