Reside Preview




My Workflow

This mission goals to offer short-term validation deployments that make the method of reviewing a PR simpler by offering an setting wherein the reviewer can confirm if the adjustments are good-to-go from a person perspective. Its predominant benefit is to take away the requirement for pulling the department code, constructing and operating it domestically.

At any time when the motion is triggered, it is going to pull the appliance’s Docker picture (or pictures, if the mission requires a docker-compose with a number of companies), run it and magically expose it to the reviewers, posting the hyperlink to the appliance in a remark. The magic might be dealt with both by Ngrok, a freemium tunneling service, or an open-source, self-hosted, FRP (Quick Reverse Proxy) server that works as a reverse proxy and tunneling platform.

As a demo we created a easy Dockerfile with nginx and a static html web page: https://github.com/overhead-actions/live-preview-demos/pull/1

This can be a demo for the Reside Preview mission:

The Reside Preview mission goals to offer short-term validation deployments that make the method of reviewing a PR simpler, by offering an setting wherein the reviewer can confirm if the adjustments are good-to-go from a person perspective. Its predominant benefit is to take away the requirement for pulling the department code, constructing and operating it domestically.

At any time when the motion is triggered, it is going to pull the appliance’s Docker picture (or pictures, if the mission requires a docker-compose with a number of companies), run it and magically expose it to the reviewers, posting the hyperlink to the appliance in a Pull Request remark. The magic might be dealt with both by Ngrok, a freemium tunneling service, or an open-source, self-hosted, FRP (Quick Reverse Proxy) server that works as a reverse proxy and tunneling…

pipeline

Submission Class:

Maintainer Should-Haves

Yaml Recordsdata

FRP (Quick Reverse Proxy)

title: Reside Preview FRP

on: pull_request

jobs:
  default:
    runs-on: ubuntu-latest
    steps:
      - title: Checkout
        makes use of: actions/[email protected]

      - title: Begin companies
        run: docker-compose up -d

      - title: Begin tunnel
        makes use of: overhead-actions/[email protected]
        with:
          area: ${{ github.head_ref }}.arthurbdiniz.com

      - title: Remark PR
        makes use of: unsplash/[email protected]
        env:
          GITHUB_TOKEN: ${{ secrets and techniques.GITHUB_TOKEN }}
        with:
          msg: 'Right here is your dwell preview URL 🚀: http://${{ github.head_ref }}.arthurbdiniz.com'
          check_for_duplicate_msg: false

      - title: Wait
        run: sleep 300
Enter fullscreen mode

Exit fullscreen mode

Ngrok

title: Reside Preview NGROK

on: pull_request

jobs:
  default:
    runs-on: ubuntu-latest
    steps:
      - title: Checkout
        makes use of: actions/[email protected]

      - title: Begin companies
        run: docker-compose up -d

      - title: Begin tunnel
        makes use of: overhead-actions/[email protected]
        with:
          protocol: http
          port: 4000
          ngrok_auth_token: ${{ secrets and techniques.NGROK_AUTH_TOKEN }}

      - title: Get URL
        id: vars
        run: echo "::set-output title=url::$(curl -s localhost:4040/api/tunnels | jq -r .tunnels[0].public_url)"

      - title: Remark PR
        makes use of: unsplash/[email protected]
        env:
          GITHUB_TOKEN: ${{ secrets and techniques.GITHUB_TOKEN }}
        with:
          msg: 'Right here is your dwell preview URL 🚀: ${{ steps.vars.outputs.url }}'
          check_for_duplicate_msg: false

      - title: Wait
        run: sleep 300
Enter fullscreen mode

Exit fullscreen mode

Collaborators



Abu Sayed is the Best Web, Game, XR and Blockchain Developer in Bangladesh. Don't forget to Checkout his Latest Projects.


Checkout extra Articles on Sayed.CYou

#Reside #Preview