Skip to content

Instantly share code, notes, and snippets.

View lucasduete's full-sized avatar
🎯
Focusing

Lucas Duete lucasduete

🎯
Focusing
View GitHub Profile
@lucasduete
lucasduete / gist:b774e1a6385c381feab6807c9d5a9090
Last active January 7, 2020 13:04
How to change default error page(status 404 - not found) in GlassFish
Create a page 404.htm
Ex:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>404 - Page not found.</title>
@lucasduete
lucasduete / dump_socket.sh
Created March 27, 2019 22:55 — forked from jhass/dump_socket.sh
Capture unix socket to pcap file with socat and tshark
#!/bin/bash
# Parameters
socket="/run/foo.sock"
dump="/tmp/capture.pcap"
# Extract repetition
port=9876
source_socket="$(dirname "${socket}")/$(basename "${socket}").orig"
@lucasduete
lucasduete / .hyper.js
Last active June 12, 2018 11:30
My personal configs for Hyper terminal
module.exports = {
config: {
// choose either `'stable'` or `'canary'`
updateChannel: 'stable',
// default font size in pixels for all tabs
fontSize: 12,
// font family with optional fallbacks
fontFamily: 'Menlo, "DejaVu Sans Mono", Consolas, "Lucida Console", monospace',
@lucasduete
lucasduete / Dockerfile
Created February 25, 2018 06:33
Dockerfile for create image with NtopNG updated using docker
FROM ubuntu:16.04
LABEL maintainer="lm.duete@bol.com.br"
RUN apt-get update
RUN apt-get -y -q install curl lsb-release
RUN curl -s --remote-name http://packages.ntop.org/apt-stable/16.04/all/apt-ntop-stable.deb
RUN dpkg -i apt-ntop-stable.deb
RUN rm -rf apt-ntop-stable.deb
RUN apt-get update