elpa firewall demo - michaelmworthington/codesamples GitHub Wiki

Introduction

This page walks through the steps to set up NXRM and a Chef Docker container to test ELPA Firewall using http://elpa.gnu.org/packages/

See the community docs at  https://github.com/sonatype-nexus-community/nexus-repository-elpa

Table of Contents

Prerequisites

  • IQ Server installed and running
  • NXRM 3 installed and running and configured with the IQ Server
  • Docker for Mac installed and running

Step 1. Create a new Proxy Repository in NXRM

Use http://elpa.gnu.org/packages/ as the Remote URL. Accept default values for the remainder of the settings.

Step 2. Enable Firewall for the New Proxy Repo

Step 3. Run the Docker Image in Interactive Mode

docker run -it --rm silex/emacs

Step 4. Use the emacs to set up the repo sources

M-x customize-variable [RET] package-archives [RET]

Fill in:

TIP: M-x means escape + x keys, and [RET] means the return key

Step 5. Use emacs to Install a package

M-x list-packages

press i to mark for installation, and x to perform the installation

Observe the inbound requests to NXRM in the request.log file:

172.17.0.1 - - [13/Nov/2020:04:10:51 +0000] "GET /repository/elpa-gnu.org-proxy/archive-contents HTTP/1.1" 200 83966 2313 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:10:52 +0000] "GET /repository/elpa-gnu.org-proxy/archive-contents.sig HTTP/1.1" 404 1903 87 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:11:10 +0000] "GET /repository/elpa-gnu.org-proxy/archive-contents HTTP/1.1" 200 83966 11 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:11:10 +0000] "GET /repository/elpa-gnu.org-proxy/archive-contents.sig HTTP/1.1" 404 1903 4 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:11:25 +0000] "GET /repository/elpa-gnu.org-proxy/aumix-mode-7.el HTTP/1.1" 200 10871 1218 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:11:27 +0000] "GET /repository/elpa-gnu.org-proxy/aumix-mode-7.el.sig HTTP/1.1" 200 438 1173 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:11:29 +0000] "GET /repository/elpa-gnu.org-proxy/auctex-12.3.1.tar HTTP/1.1" 200 6666240 1999 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:11:30 +0000] "GET /repository/elpa-gnu.org-proxy/auctex-12.3.1.tar.sig HTTP/1.1" 200 438 1017 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:11:46 +0000] "GET /repository/elpa-gnu.org-proxy/async-1.9.3.tar HTTP/1.1" 200 112640 1577 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:11:47 +0000] "GET /repository/elpa-gnu.org-proxy/async-1.9.3.tar.sig HTTP/1.1" 200 438 1217 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:11:49 +0000] "GET /repository/elpa-gnu.org-proxy/ascii-art-to-unicode-1.12.el HTTP/1.1" 200 20803 1204 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:11:50 +0000] "GET /repository/elpa-gnu.org-proxy/ascii-art-to-unicode-1.12.el.sig HTTP/1.1" 200 438 1008 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:11:50 +0000] "GET /repository/elpa-gnu.org-proxy/arbitools-0.977.el HTTP/1.1" 500 1968 92 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:15:50 +0000] "GET /repository/elpa-gnu.org-proxy/archive-contents HTTP/1.1" 200 83966 22 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"
172.17.0.1 - - [13/Nov/2020:04:15:50 +0000] "GET /repository/elpa-gnu.org-proxy/archive-contents.sig HTTP/1.1" 404 1903 8 "URL/Emacs Emacs/27.1 (TTY; x86_64-pc-linux-gnu)"

Step 6. Browse the Proxy Repo

Step 7. Go to the Firewall Report

Repo List

IQ Server Report

Step 8. Test Quarantine

Not Supported

Step 9. Notes

You can view the component information panel (CIP) right in NXRM

Not Supported
⚠️ **GitHub.com Fallback** ⚠️