diff --git a/.github/dockerfiles/Dockerfile.ubuntu-base b/.github/dockerfiles/Dockerfile.ubuntu-base index 0b6a1c146525..dac99535a8d6 100644 --- a/.github/dockerfiles/Dockerfile.ubuntu-base +++ b/.github/dockerfiles/Dockerfile.ubuntu-base @@ -122,10 +122,8 @@ RUN export PATH="$(cat /home/${USER}/LATEST):${PATH}" && \ jq '.tarball_url' | xargs curl -L > hex.tar.gz && \ tar xzf hex.tar.gz --strip-components=1 && \ mix install && \ - mkdir /buildroot/ex_doc && cd /buildroot/ex_doc && \ - curl -s https://api.github.com/repos/elixir-lang/ex_doc/releases/${EX_DOC_VSN} | \ - jq '.tarball_url' | xargs curl -L > ex_doc.tar.gz && \ - tar xzf ex_doc.tar.gz --strip-components=1 && \ + git clone https://github.com/garazdawi/ex_doc /buildroot/ex_doc && \ + cd /buildroot/ex_doc && \ mix deps.get && MIX_ENV=prod mix escript.build && \ sudo cp ex_doc /usr/local/bin/ diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index 1a3dba929846..8471fc736515 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -387,6 +387,10 @@ jobs: name: Build and check documentation runs-on: ubuntu-latest needs: pack + # Grant GITHUB_TOKEN the permissions required to make a Pages deployment + permissions: + pages: write # to deploy to Pages + id-token: write # to verify the deployment originates from an appropriate source steps: - uses: actions/checkout@v4.1.1 - uses: ./.github/actions/build-base-image @@ -411,12 +415,21 @@ jobs: docker run -v $PWD/:/github otp \ "make release_docs DOC_TARGETS='html' RELEASE_ROOT=/github/docs" sudo chown -R `whoami` docs + echo '' > docs/index.html cd docs && tar czf ../otp_doc_html.tar.gz * - name: Upload html documentation archive uses: actions/upload-artifact@v4.1.0 with: name: otp_doc_html path: otp_doc_html.tar.gz + - name: Upload artifact + uses: actions/upload-pages-artifact@v2 + with: + # Upload entire repository + path: 'docs' + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v2 - name: Run html link check run: docker run -v $PWD/:/github otp "cd /github/docs && /github/scripts/otp_check_html_links.exs" @@ -450,8 +463,8 @@ jobs: strategy: matrix: # type: ${{ fromJson(needs.pack.outputs.all) }} - type: ${{ fromJson(needs.pack.outputs.changes) }} - # type: ["os_mon","sasl"] + # type: ${{ fromJson(needs.pack.outputs.changes) }} + type: ["os_mon","sasl"] fail-fast: false steps: - uses: actions/checkout@v4.1.1