🦈🏠🐜 Initial Commit 🐜🦈🏠

This commit is contained in:
Jason 2022-02-14 16:44:52 -05:00
commit 692354daec
No known key found for this signature in database
GPG Key ID: 4F765975C1F0EE5F
29 changed files with 23242 additions and 0 deletions

19
.gitignore vendored Normal file
View File

@ -0,0 +1,19 @@
# gitignore created on 02/09/22 at 12:16
# Disable reminder in prompt
ignoredirmessage
# OS generated files
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db
# Other
.installed
# ignore commit message
.gitcommit

36
Dockerfile Normal file
View File

@ -0,0 +1,36 @@
FROM casjaysdev/golang AS builder
WORKDIR /app/gohttpserver
RUN apk -U upgrade && \
apk add git && \
git clone "https://github.com/codeskyblue/gohttpserver" ./ && \
CGO_ENABLED=0 GOOS=linux go build -ldflags '-X main.VERSION=docker' -o gohttpserver && \
chmod +x gohttpserver
FROM casjaysdev/alpine:latest
ARG BUILD_DATE="$(date +'%Y-%m-%d %H:%M')"
LABEL \
org.label-schema.name="gohttpserver" \
org.label-schema.description="Alpine based image with gohttpserver." \
org.label-schema.url="https://github.com/casjaysdev/gohttpserver" \
org.label-schema.vcs-url="https://github.com/casjaysdev/gohttpserver" \
org.label-schema.build-date=$BUILD_DATE \
org.label-schema.version=$BUILD_DATE \
org.label-schema.vcs-ref=$BUILD_DATE \
org.label-schema.license="MIT" \
org.label-schema.vcs-type="Git" \
org.label-schema.schema-version="1.0" \
org.label-schema.vendor="CasjaysDev" \
maintainer="CasjaysDev <docker-admin@casjaysdev.com>"
COPY --from=builder /app/gohttpserver/gohttpserver /usr/local/bin/gohttpserver
COPY ./data/. /data/
COPY ./config/. /config/
COPY ./bin/. /usr/local/bin/
WORKDIR /data/htdocs
EXPOSE 19065
HEALTHCHECK CMD [ "/usr/local/bin/entrypoint-gohttpserver.sh", "healthcheck" ]
ENTRYPOINT [ "/usr/local/bin/entrypoint-gohttpserver.sh"]

13
LICENSE.md Normal file
View File

@ -0,0 +1,13 @@
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2022 Jason Hempstead <git-admin@casjaysdev.com>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
1. You just DO WHAT THE FUCK YOU WANT TO.

10
README.md Normal file
View File

@ -0,0 +1,10 @@
<h1 align=center>
👋 Welcome to gohttpserver 👋
</h1>
<p align=center>
StartDocumentationHere
</p>
## Author
👤 **Jason Hempstead**

View File

@ -0,0 +1,76 @@
#!/usr/bin/env bash
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
##@Version : 202202020147-git
# @Author : Jason Hempstead
# @Contact : jason@casjaysdev.com
# @License : WTFPL
# @ReadME : docker-entrypoint --help
# @Copyright : Copyright: (c) 2022 Jason Hempstead, Casjays Developments
# @Created : Wednesday, Feb 02, 2022 01:47 EST
# @File : docker-entrypoint
# @Description :
# @TODO :
# @Other :
# @Resource :
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
APPNAME="$(basename "$0")"
VERSION="202202020147-git"
USER="${SUDO_USER:-${USER}}"
HOME="${USER_HOME:-${HOME}}"
SRC_DIR="${BASH_SOURCE%/*}"
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Set bash options
if [[ "$1" == "--debug" ]]; then shift 1 && set -xo pipefail && export SCRIPT_OPTS="--debug" && export _DEBUG="on"; fi
trap 'exitCode=${exitCode:-$?};[ -n "$DOCKER_ENTRYPOINT_TEMP_FILE" ] && [ -f "$DOCKER_ENTRYPOINT_TEMP_FILE" ] && rm -Rf "$DOCKER_ENTRYPOINT_TEMP_FILE" &>/dev/null' EXIT
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
HOSTADMIN="${HOSTADMIN:-admin@localhost}"
SSL="${SSL:-}"
export TZ="${TZ:-America/New_York}"
export HOSTNAME="${HOSTNAME:-casjaysdev-gohttpserver}"
[ -n "${TZ}" ] && echo "${TZ}" >/etc/timezone
[ -n "${HOSTNAME}" ] && echo "${HOSTNAME}" >/etc/hostname
[ -n "${HOSTNAME}" ] && echo "127.0.0.1 $HOSTNAME localhost" >/etc/hosts
[ -f "/usr/share/zoneinfo/${TZ}" ] && ln -sf "/usr/share/zoneinfo/${TZ}" "/etc/localtime"
if [ -f "/config/ssl/server.crt" ] && [ -f "/config/ssl/server.key" ]; then
SSL="on"
SSL_CERT="/config/ssl/server.crt"
SSL_KEY="/config/ssl/server.key"
if [ -f "/config/ssl/ca.crt" ]; then
cat "/config/ssl/ca.crt" >>"/etc/ssl/certs/ca-certificates.crt"
fi
elif [ "$SSL" = "on" ]; then
create-ssl-cert "/config/ssl"
fi
update-ca-certificates
if [ "$SSL" = on ] && [ -z "$CONFIG" ]; then
CONFIG="--cert=$SSL_CERT --key=$SSL_KEY"
else
CONFIG=""
fi
case "$1" in
healthcheck)
if curl -q -LSsf -o /dev/null -s -w "200" "http://localhost/server-health"; then
echo "OK"
exit 0
else
echo "FAIL"
exit 10
fi
;;
bash | shell | sh)
shift 1
ARGS="$*"
exec /bin/bash ${ARGS:--l}
;;
*)
exec gohttpserver --title=DevSystem --cors --xheaders --theme=black --addr=0.0.0.0 --port=${PORT:-19065} --root=/data/htdocs/www $CONFIG
;;
esac

73
data/htdocs/www/404.html Normal file
View File

@ -0,0 +1,73 @@
<!DOCTYPE html>
<html lang="">
<head>
<meta charset="utf-8" />
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="generator" content="CasjaysDev" />
<meta name="robots" content="index, follow" />
<meta name="description" content="" />
<meta
name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0"
/>
<meta property="og:title" content="" />
<meta property="og:type" content="" />
<meta property="og:url" content="" />
<meta property="og:image" content="" />
<meta name="theme-color" content="#fafafa" />
<link rel="manifest" href="./site.webmanifest" />
<link rel="icon" sizes="any" href="./images/favicon.ico" />
<link rel="icon" type="image/svg+xml" href="./images/icon.svg" />
<link rel="apple-touch-icon" href="./images/icon.png" />
<link rel="stylesheet" href="./css/index.css" />
<link rel="stylesheet" href="./css/errorpages.css" />
<script src="./js/errorpages/isup.js" defer></script>
<script src="./js/errorpages/homepage.js" defer></script>
<script src="./js/errorpages/loaddomain.js" defer></script>
<script src="./js/jquery/default.js"></script>
<script src="./js/passprotect.min.js" defer></script>
<script src="./js/bootstrap.min.js" defer></script>
<script src="./js/app.js" defer></script>
<title>404 Not Found</title>
</head>
<body onload="javascript:loadDomain();">
<!-- Error Page Content -->
<div class="container vh-100">
<div class="jumbotron">
<h1>
<i class="fa fa-frown-o red"></i>
<a
href="https://www.google.com/search?q=server+error+404"
target="_blank"
>404 Not Found</a
>
</h1>
<p class="lead">
We apologize but we can't seem to be able to find what you're looking
for!
</p>
<img
alt="error"
src="./images/404.gif"
height="350"
width="auto"
/><br />
</div>
<a
onclick="javascript:homepage();"
class="btn btn-secondary btn-outline-danger btn-lg btn-block"
><span id="display-domain"></span
></a>
</div>
</body>
</html>

10531
data/htdocs/www/css/bootstrap.min.css vendored Normal file

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,342 @@
@import url(
https://fonts.googleapis.com/css?family=Lato:300italic,
700italic,
300,
700
);
body {
padding: 50px;
font: 14px/1.5 Lato, "Helvetica Neue", Helvetica, Arial, sans-serif;
color: #777;
font-weight: 300;
padding: 1.5em 0;
}
/* Layout */
.jumbotron {
line-height: 2.1428571435;
color: inherit;
padding: 10px 0px;
}
/* Main marketing message and sign up button */
.jumbotron {
text-align: center;
background-color: transparent;
}
.jumbotron .btn {
font-size: 21px;
padding: 1.5em 2em;
}
/* Everything but the jumbotron gets side spacing for mobile-first views */
.masthead,
.body-content {
padding: 0 15px;
}
/* Colors */
.green {
color: green;
}
.orange {
color: orange;
}
.red {
color: red;
}
.blue {
color: blue;
}
.yellow {
color: yellow;
}
h2,
h3,
h4,
h5,
h6 {
color: #222;
margin: 0 0 40px;
}
p,
ul,
ol,
table,
pre,
dl {
margin: 0 0 20px;
}
h2,
h3 {
line-height: 1.1;
}
h1 {
line-height: 1.1;
text-align: center;
font: Lato;
font-size: 80px;
color: #222;
margin: 0 0 40px;
}
h2 {
color: #393939;
}
h3,
h4,
h5,
h6 {
color: #494949;
}
a {
color: #39c;
font-weight: 400;
text-decoration: none;
}
a small {
font-size: 11px;
color: #777;
margin-top: -0.6em;
display: block;
}
.wrapper {
width: 860px;
margin: 0 auto;
}
blockquote {
border-left: 1px solid #e5e5e5;
margin: 0;
padding: 0 0 0 20px;
font-style: italic;
}
.btn-block {
width: 40%;
text-align: center;
display: block;
margin: 0 auto;
}
code,
pre {
font-family: Monaco, Bitstream Vera Sans Mono, Lucida Console, Terminal;
color: #333;
font-size: 12px;
}
pre {
padding: 8px 15px;
background: #f8f8f8;
border-radius: 5px;
border: 1px solid #e5e5e5;
overflow-x: auto;
}
table {
width: 100%;
border-collapse: collapse;
}
th,
td {
text-align: left;
padding: 5px 10px;
border-bottom: 1px solid #e5e5e5;
}
dt {
color: #444;
font-weight: 700;
}
th {
color: #444;
}
img {
max-width: 100%;
}
header {
width: 270px;
float: left;
position: fixed;
}
header ul {
list-style: none;
height: 40px;
padding: 0;
background: #eee;
background: -moz-linear-gradient(top, #f8f8f8 0%, #dddddd 100%);
background: -webkit-gradient(
linear,
left top,
left bottom,
color-stop(0%, #f8f8f8),
color-stop(100%, #dddddd)
);
background: -webkit-linear-gradient(top, #f8f8f8 0%, #dddddd 100%);
background: -o-linear-gradient(top, #f8f8f8 0%, #dddddd 100%);
background: -ms-linear-gradient(top, #f8f8f8 0%, #dddddd 100%);
background: linear-gradient(top, #f8f8f8 0%, #dddddd 100%);
border-radius: 5px;
border: 1px solid #d2d2d2;
box-shadow: inset #fff 0 1px 0, inset rgba(0, 0, 0, 0.03) 0 -1px 0;
width: 270px;
}
header li {
width: 89px;
float: left;
border-right: 1px solid #d2d2d2;
height: 40px;
}
header ul a {
line-height: 1;
font-size: 11px;
color: #999;
display: block;
text-align: center;
padding-top: 6px;
height: 40px;
}
strong {
color: #222;
font-weight: 700;
}
header ul li + li {
width: 88px;
border-left: 1px solid #fff;
}
header ul li + li + li {
border-right: none;
width: 89px;
}
header ul a strong {
font-size: 14px;
display: block;
color: #222;
}
section {
width: 500px;
float: right;
padding-bottom: 50px;
}
small {
font-size: 11px;
}
hr {
border: 0;
background: #e5e5e5;
height: 1px;
margin: 0 0 20px;
}
footer {
width: 270px;
float: left;
position: fixed;
bottom: 50px;
}
@media print, screen and (max-width: 960px) {
div.wrapper {
width: auto;
margin: 0;
}
header,
section,
footer {
float: none;
position: static;
width: auto;
}
header {
padding-right: 320px;
}
section {
border: 1px solid #e5e5e5;
border-width: 1px 0;
padding: 20px 0;
margin: 0 0 20px;
}
header a small {
display: inline;
}
header ul {
position: absolute;
right: 50px;
top: 52px;
}
}
@media print, screen and (max-width: 720px) {
body {
word-wrap: break-word;
}
header {
padding: 0;
}
header ul,
header p.view {
position: static;
}
pre,
code {
word-wrap: normal;
}
}
@media print, screen and (max-width: 480px) {
body {
padding: 15px;
}
header ul {
display: none;
}
}
@media print {
body {
padding: 0.4in;
font-size: 12pt;
color: #444;
}
}

View File

@ -0,0 +1,79 @@
@import url(http://fonts.googleapis.com/css?family=Open+Sans:400,300,600,700);
@import url(./bootstrap.min.css);
body {
color: purple;
background-image: url('../images/bg.png');
}
th {
background-color: #333;
color: #ffffff;
border-top: 1px solid #678ca0;
vertical-align: middle;
height: 50px;
}
td {
background-color: 333;
border-top: 1px solid #678ca0;
}
.box {
border: 1px solid #678ca0;
padding: 0px;
width: 100%;
background-color: #333;
margin-bottom: 10px;
width: 600px;
}
.spacer {
margin: 0px;
width: 100%;
background-color: #333;
}
.leftspacer {
margin: 0px;
padding: 5px;
width: 100%;
text-align: left;
background-color: #333;
}
.serviceup {
color: green;
}
.servicedown {
color: red;
}
a {
text-decoration: none;
color: #5d83a9;
}
p.main {
margin-top: 5px;
margin-bottom: 5px;
text-align: center;
font-size: 10px;
}
a:visited {
color: #c39;
}
a:hover {
color: #f00;
}
a:active {
color: #c0f;
}
tr:hover {
background-color: #f5f5f5;
}

1
data/htdocs/www/favicon.ico Symbolic link
View File

@ -0,0 +1 @@
./images/favicon.ico

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 93 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 766 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

View File

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" viewBox="0 0 192 192"><path fill="#e08524" d="M75.3 73.4H18.4l45.3 34.3L48.3 163l46.1-32.3 48.2 34.6-16.9-58.3 44.9-33.6H115l-20.5-55-19.2 55z"/><path d="m96.7 18.8 18.2 8.2 16.5 44.3h-15.1L96.7 18.8zm-47 146 18.7 9.9 42.6-29.9-16.5-11.4-44.8 31.4zm79.1-56.8 17.4 9.4 18.6 60.1-19.7-11.3-16.3-58.2z"/><path d="m173.1 74.3 17.8 9.2-44.7 34-17.4-9.4 44.3-33.8z"/></svg>

After

Width:  |  Height:  |  Size: 429 B

View File

@ -0,0 +1,48 @@
<!DOCTYPE html>
<html lang="">
<head>
<meta charset="utf-8" />
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="generator" content="CasjaysDev" />
<meta name="robots" content="index, follow" />
<meta name="description" content="" />
<meta
name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0"
/>
<meta property="og:title" content="" />
<meta property="og:type" content="" />
<meta property="og:url" content="" />
<meta property="og:image" content="" />
<meta name="theme-color" content="#fafafa" />
<link rel="manifest" href="./site.webmanifest" />
<link rel="icon" sizes="any" href="./images/favicon.ico" />
<link rel="icon" type="image/svg+xml" href="./images/icon.svg" />
<link rel="apple-touch-icon" href="./images/icon.png" />
<link rel="stylesheet" href="./css/index.css" />
<script src="./js/errorpages/isup.js" defer></script>
<script src="./js/errorpages/homepage.js" defer></script>
<script src="./js/errorpages/loaddomain.js" defer></script>
<script src="./js/jquery/default.js"></script>
<script src="./js/passprotect.min.js" defer></script>
<script src="./js/bootstrap.min.js" defer></script>
<script src="./js/app.js" defer></script>
<title>Welcome</title>
</head>
<body>
<div class="container text-center">
<h1 class="m-5">Congratulations</h1>
<h2>
Your apache container has been setup.<br /><br /><br /><br /><br />
</h2>
</div>
</body>
</html>

46
data/htdocs/www/info.php Normal file
View File

@ -0,0 +1,46 @@
<!DOCTYPE html>
<html lang="">
<head>
<meta charset="utf-8" />
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="generator" content="CasjaysDev" />
<meta name="robots" content="index, follow" />
<meta name="description" content="" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0" />
<meta property="og:title" content="" />
<meta property="og:type" content="" />
<meta property="og:url" content="" />
<meta property="og:image" content="" />
<meta name="theme-color" content="#fafafa" />
<link rel="manifest" href="./site.webmanifest" />
<link rel="icon" sizes="any" href="./images/favicon.ico" />
<link rel="icon" type="image/svg+xml" href="./images/icon.svg" />
<link rel="apple-touch-icon" href="./images/icon.png" />
<link rel="stylesheet" href="./css/index.css" />
<script src="./js/errorpages/isup.js" defer></script>
<script src="./js/errorpages/homepage.js" defer></script>
<script src="./js/errorpages/loaddomain.js" defer></script>
<script src="./js/jquery/default.js"></script>
<script src="./js/passprotect.min.js" defer></script>
<script src="./js/bootstrap.min.js" defer></script>
<script src="./js/app.js" defer></script>
<title>Welcome</title>
</head>
<body>
<div class="container text-center">
<h1 class="m-5">Congratulations</h1>
<php phpinfo(); ?>
<br /><br /><br /><br /><br />
</div>
</body>
</html>

View File

4075
data/htdocs/www/js/bootstrap.min.js vendored Normal file

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,6 @@
function homepage() {
let proto = location.protocol;
let port = location.port;
let currentSite = window.location.hostname;
window.location = proto + '//' + currentSite + ':' + port;
}

View File

@ -0,0 +1,7 @@
function isupme() {
let proto = location.protocol;
let port = location.port;
let currentSite = window.location.hostname;
fullurllocation = proto + '//' + currentSite + ':' + port;
window.location = 'http://isup.me/' + fullurllocation;
}

View File

@ -0,0 +1,7 @@
function loadDomain() {
let proto = location.protocol;
let port = location.port;
let url = location.hostname;
var display = document.getElementById('display-domain');
display.innerHTML = proto + '//' + url + ':' + port;
}

View File

@ -0,0 +1,20 @@
var metas = document.getElementsByTagName('meta');
var i;
if (navigator.userAgent.match(/iPhone/i)) {
for (i = 0; i < metas.length; i++) {
if (metas[i].name == 'viewport') {
metas[i].content =
'width=device-width, minimum-scale=1.0, maximum-scale=1.0';
}
}
document.addEventListener('gesturestart', gestureStart, false);
}
function gestureStart() {
for (i = 0; i < metas.length; i++) {
if (metas[i].name == 'viewport') {
metas[i].content =
'width=device-width, minimum-scale=0.25, maximum-scale=1.6';
}
}
}

5540
data/htdocs/www/js/jquery/default.js vendored Normal file

File diff suppressed because it is too large Load Diff

2294
data/htdocs/www/js/passprotect.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1 @@
ok

View File

@ -0,0 +1,3 @@
{
"status": "ok"
}

View File

@ -0,0 +1,14 @@
{
"short_name": "",
"name": "",
"icons": [
{
"src": "./images/icon.png",
"type": "image/png",
"sizes": "192x192"
}
],
"start_url": "/",
"background_color": "#000000",
"theme_color": "#ffffff"
}