mkbrut 0.2.7 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/mkbrut/segments/bare_bones.rb +6 -5
- data/lib/mkbrut/version.rb +1 -1
- data/templates/Base/app/src/front_end/images/LogoPylon.png +0 -0
- data/templates/Base/app/src/front_end/images/LogoTransit.png +0 -0
- data/templates/Base/app/src/front_end/images/apple-touch-icon-120x120.png +0 -0
- data/templates/Base/app/src/front_end/images/apple-touch-icon-152x152.png +0 -0
- data/templates/Base/app/src/front_end/images/apple-touch-icon-167x167.png +0 -0
- data/templates/Base/app/src/front_end/images/apple-touch-icon-180x180.png +0 -0
- data/templates/Base/app/src/front_end/images/favicon.ico +0 -0
- data/templates/Base/app/src/front_end/images/icon.png +0 -0
- data/templates/Base/app/src/front_end/pages/home_page.rb +62 -0
- data/templates/Base/docker-compose.dx.yml +6 -1
- data/templates/Base/dx/exec +17 -5
- data/templates/segments/Heroku/deploy/docker-entrypoint +15 -0
- metadata +5 -2
- data/templates/Base/app/src/front_end/pages/home_page.rb.erb +0 -54
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 847d6f7efc89998a82712ddf8cb57f606b718479fd06b28057c668b096794519
|
4
|
+
data.tar.gz: 1e603967946eccb5744c173c02b19f42ad8596d390d2dcf9bf68fd07693b045f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 92a6f6c3f1309aa69c73a394bff444984ee605f3a5434e59ddeb767db91798e65350aeb474525a27618868ccefcc2b805f09ccd1c81fbd332ef06b979b936f30
|
7
|
+
data.tar.gz: c5c7f161f8a67c805892aa7c4fe393ad9b53d92cb2bad22d32edacf7bb2f152dc54546b6f1e1a624eab1bb59a50d93e9522527a09c61c7899406949bf66a2ed9
|
@@ -50,18 +50,19 @@ end},
|
|
50
50
|
code: %{
|
51
51
|
#{ @erb_binding.prefix }_example(
|
52
52
|
transform: "upper",
|
53
|
-
class: [ "
|
53
|
+
class: [ "pos-fixed",
|
54
|
+
"bottom-0",
|
55
|
+
"left-0",
|
56
|
+
"w-100",
|
57
|
+
"ff-sans",
|
54
58
|
"lh-title",
|
55
59
|
"tracked",
|
56
60
|
"f-5",
|
57
61
|
"f-6-ns",
|
58
|
-
"bg-green-100",
|
59
|
-
"red-900",
|
60
62
|
"tc",
|
61
63
|
"pa-3",
|
62
64
|
"mt-3",
|
63
|
-
"db",
|
64
|
-
]
|
65
|
+
"db", ]
|
65
66
|
) do
|
66
67
|
"We Like the Web"
|
67
68
|
end
|
data/lib/mkbrut/version.rb
CHANGED
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -0,0 +1,62 @@
|
|
1
|
+
class HomePage < AppPage
|
2
|
+
def page_template
|
3
|
+
# The duplication and excessive class sizes here are to
|
4
|
+
# make it easier for you to remove this when you start working
|
5
|
+
# on your app. There are pros and cons to how this code
|
6
|
+
# is written, so don't take this is as a directive on how to
|
7
|
+
# build your app. You do you!
|
8
|
+
img(src: "/static/images/LogoPylon.png",
|
9
|
+
class: "dn db-ns pos-fixed top-0 left-0 h-100vh w-auto z-2")
|
10
|
+
|
11
|
+
header(class: "flex flex-column items-center justify-center h-100vh") do
|
12
|
+
div(class: "flex flex-column flex-row-ns items-center justify-center gap-3") do
|
13
|
+
img(src: "/static/images/LogoTransit.png", class: "h-5")
|
14
|
+
div do
|
15
|
+
h1(class: "ff-sans ma-0 lh-title f-5 tc tl-ns flex flex-column flex-row-ns items-center gap-2") do
|
16
|
+
plain("Welcome to Brut")
|
17
|
+
end
|
18
|
+
h2(class: "ff-sans ma-0 lh-title f-3 fw-normal tc tl-ns") do
|
19
|
+
plain("v")
|
20
|
+
plain(Gem.loaded_specs["brut"].version.to_s)
|
21
|
+
end
|
22
|
+
|
23
|
+
end
|
24
|
+
end
|
25
|
+
nav(class: [ "ff-sans",
|
26
|
+
"flex",
|
27
|
+
"flex-column",
|
28
|
+
"flex-row-ns",
|
29
|
+
"items-center",
|
30
|
+
"justify-start",
|
31
|
+
"gap-3",
|
32
|
+
"mt-3",
|
33
|
+
]) do
|
34
|
+
a(href: "https://brutrb.com",
|
35
|
+
target: "_blank",
|
36
|
+
class: "f-3 red-300 tdu tdn-ns hover-tdu-ns"
|
37
|
+
) do
|
38
|
+
code { "brutrb.com" }
|
39
|
+
end
|
40
|
+
span(role: "separator", class: "dn di-ns f-3 red-300") do
|
41
|
+
raw(safe "⊙")
|
42
|
+
end
|
43
|
+
a(href: "https://brutrb.com/api/index.html",
|
44
|
+
target: "_blank",
|
45
|
+
class: "f-3 red-300 tdu tdn-ns hover-tdu-ns"
|
46
|
+
) do
|
47
|
+
"API Docs"
|
48
|
+
end
|
49
|
+
span(role: "separator", class: "dn di-ns f-3 red-300") do
|
50
|
+
raw(safe "⊙")
|
51
|
+
end
|
52
|
+
a(href: "http://localhost:6504",
|
53
|
+
target: "_blank",
|
54
|
+
class: "f-3 red-300 tdu tdn-ns hover-tdu-ns"
|
55
|
+
) do
|
56
|
+
"Local OpenTelemetry"
|
57
|
+
end
|
58
|
+
end
|
59
|
+
end
|
60
|
+
|
61
|
+
end
|
62
|
+
end
|
@@ -39,7 +39,7 @@ services:
|
|
39
39
|
target: "/var/run/docker.sock"
|
40
40
|
# This is what is started up when you run `dx/start`. It just
|
41
41
|
# waits forever keeping the container running.
|
42
|
-
|
42
|
+
command: /home/appuser/show-help-in-app-container-then-wait.sh
|
43
43
|
# The working directory for any command, this is the same as your
|
44
44
|
# project root.
|
45
45
|
working_dir: ${PWD}
|
@@ -52,6 +52,11 @@ services:
|
|
52
52
|
# This exposes ports from this running container to your localhost.
|
53
53
|
# In this case, we expose 6502, where the app runs, and 6503, where
|
54
54
|
# the test server runs.
|
55
|
+
#
|
56
|
+
# To change this, the port before the colon is where the app
|
57
|
+
# will be available on your localhost. The port AFTER the colon is where
|
58
|
+
# the app runs in the container. So: change the port before the colon, and
|
59
|
+
# don't change the one after.
|
55
60
|
ports:
|
56
61
|
- "6502:6502"
|
57
62
|
- "6503:6503"
|
data/templates/Base/dx/exec
CHANGED
@@ -9,17 +9,21 @@ SCRIPT_DIR=$( cd -- "$( dirname -- "${0}" )" > /dev/null 2>&1 && pwd )
|
|
9
9
|
require_command "docker"
|
10
10
|
load_docker_compose_env
|
11
11
|
|
12
|
-
usage_description="Execute a command inside the app's container."
|
13
|
-
usage_args="[-s service] command"
|
12
|
+
usage_description="Execute a command inside the app's container. Any command other than 'bash' will be run with bash -lc. Use -B to just run the command directly."
|
13
|
+
usage_args="[-s service] [-B] command"
|
14
14
|
usage_pre="exec.pre"
|
15
15
|
usage_on_help "${usage_description}" "${usage_args}" "${usage_pre}" "" "${@}"
|
16
16
|
|
17
17
|
SERVICE="${SERVICE_NAME:-${DEFAULT_SERVICE}}"
|
18
|
-
|
18
|
+
INCLUDE_PREFIX_FOR_NON_BASH=true
|
19
|
+
while getopts "s:B" opt "${@}"; do
|
19
20
|
case ${opt} in
|
20
21
|
s )
|
21
22
|
SERVICE="${OPTARG}"
|
22
23
|
;;
|
24
|
+
B )
|
25
|
+
INCLUDE_PREFIX_FOR_NON_BASH=false
|
26
|
+
;;
|
23
27
|
\? )
|
24
28
|
log "🛑" "Unknown option: ${opt}"
|
25
29
|
usage "${description}" "${usage_args}" "${usage_pre}"
|
@@ -42,7 +46,15 @@ if ! exec_hook_if_exists "exec.pre"; then
|
|
42
46
|
exit 1
|
43
47
|
fi
|
44
48
|
|
45
|
-
|
49
|
+
if [ "$#" -eq 1 ] && [ "$1" = "bash" ]; then
|
50
|
+
COMMAND=(bash)
|
51
|
+
elif [ "$INCLUDE_PREFIX_FOR_NON_BASH" = "true" ]; then
|
52
|
+
COMMAND=(bash -lc "$*")
|
53
|
+
else
|
54
|
+
COMMAND=("$@")
|
55
|
+
fi
|
56
|
+
|
57
|
+
log "🚂" "Running '${COMMAND[@]}' inside container with service name '${SERVICE}'"
|
46
58
|
|
47
59
|
docker \
|
48
60
|
compose \
|
@@ -51,6 +63,6 @@ docker \
|
|
51
63
|
--env-file "${ENV_FILE}" \
|
52
64
|
exec \
|
53
65
|
"${SERVICE}" \
|
54
|
-
"${@}"
|
66
|
+
"${COMMAND[@]}"
|
55
67
|
|
56
68
|
# vim: ft=bash
|
@@ -0,0 +1,15 @@
|
|
1
|
+
#!/bin/bash -e
|
2
|
+
|
3
|
+
# This is the Docker entrypoint, mean this script is used to execute
|
4
|
+
# the command given to the RUN directive.
|
5
|
+
#
|
6
|
+
# The reason this exists is to load jemalloc. If you don't want to use
|
7
|
+
# jemalloc, you can delete this script, as well as the ENTRYPOINT directive
|
8
|
+
# in deploy/Dockerfile.
|
9
|
+
|
10
|
+
# Enable jemalloc for reduced memory usage and latency.
|
11
|
+
if [ -z "${LD_PRELOAD+x}" ] && [ -f /usr/lib/*/libjemalloc.so.2 ]; then
|
12
|
+
export LD_PRELOAD="$(echo /usr/lib/*/libjemalloc.so.2)"
|
13
|
+
fi
|
14
|
+
|
15
|
+
exec "${@}"
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mkbrut
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dave Copeland
|
@@ -109,6 +109,8 @@ files:
|
|
109
109
|
- templates/Base/app/src/front_end/fonts/monaspace-xenon.ttf
|
110
110
|
- templates/Base/app/src/front_end/forms/app_form.rb
|
111
111
|
- templates/Base/app/src/front_end/handlers/app_handler.rb
|
112
|
+
- templates/Base/app/src/front_end/images/LogoPylon.png
|
113
|
+
- templates/Base/app/src/front_end/images/LogoTransit.png
|
112
114
|
- templates/Base/app/src/front_end/images/apple-touch-icon-120x120.png
|
113
115
|
- templates/Base/app/src/front_end/images/apple-touch-icon-152x152.png
|
114
116
|
- templates/Base/app/src/front_end/images/apple-touch-icon-167x167.png
|
@@ -119,7 +121,7 @@ files:
|
|
119
121
|
- templates/Base/app/src/front_end/js/index.js
|
120
122
|
- templates/Base/app/src/front_end/layouts/default_layout.rb.erb
|
121
123
|
- templates/Base/app/src/front_end/pages/app_page.rb
|
122
|
-
- templates/Base/app/src/front_end/pages/home_page.rb
|
124
|
+
- templates/Base/app/src/front_end/pages/home_page.rb
|
123
125
|
- templates/Base/app/src/front_end/support/app_session.rb
|
124
126
|
- templates/Base/app/src/front_end/svgs/README.md
|
125
127
|
- templates/Base/app/src/front_end/svgs/comment-button.svg
|
@@ -181,6 +183,7 @@ files:
|
|
181
183
|
- templates/segments/Demo/specs/front_end/pages/new_guestbook_message_page.spec.rb
|
182
184
|
- templates/segments/Heroku/bin/deploy
|
183
185
|
- templates/segments/Heroku/deploy/Dockerfile
|
186
|
+
- templates/segments/Heroku/deploy/docker-entrypoint
|
184
187
|
- templates/segments/Heroku/deploy/heroku_config.rb
|
185
188
|
homepage: https://brutrb.com
|
186
189
|
licenses: []
|
@@ -1,54 +0,0 @@
|
|
1
|
-
class HomePage < AppPage
|
2
|
-
def page_template
|
3
|
-
# The duplication and excessive class sizes here are to
|
4
|
-
# make it easier for you to remove this when you start working
|
5
|
-
# on your app. There are pros and cons to how this code
|
6
|
-
# is written, so don't take this is as a directive on how to
|
7
|
-
# build your app. You do you!
|
8
|
-
div(class: "flex flex-column items-center justify-center h-80vh") do
|
9
|
-
img(src: "/static/images/icon.png", class: "h-50")
|
10
|
-
h1(class: "ff-sans ma-0 lh-title f-5") do
|
11
|
-
"Welcome to Brut"
|
12
|
-
end
|
13
|
-
h2(class: "ff-sans ma-0 lh-title f-4 fw-normal") do
|
14
|
-
plain("Version ")
|
15
|
-
plain(Gem.loaded_specs["brut"].version.to_s)
|
16
|
-
end
|
17
|
-
|
18
|
-
nav(class: [ "ff-sans",
|
19
|
-
"flex",
|
20
|
-
"flex-column",
|
21
|
-
"flex-row-ns",
|
22
|
-
"items-center",
|
23
|
-
"justify-between",
|
24
|
-
"gap-3",
|
25
|
-
"mt-3",
|
26
|
-
"ph-3"
|
27
|
-
]) do
|
28
|
-
a(href: "https://brutrb.com",
|
29
|
-
target: "_blank",
|
30
|
-
class: "f-3 red-300 tdu tdn-ns hover-tdu-ns") do
|
31
|
-
code { "brutrb.com" }
|
32
|
-
end
|
33
|
-
span(role: "separator",
|
34
|
-
class: "dn di-ns f-3 red-300") do
|
35
|
-
raw(safe "✣")
|
36
|
-
end
|
37
|
-
a(href: "https://brutrb.com/api/index.html",
|
38
|
-
target: "_blank",
|
39
|
-
class: "f-3 red-300 tdu tdn-ns hover-tdu-ns") do
|
40
|
-
"API Docs"
|
41
|
-
end
|
42
|
-
span(role: "separator",
|
43
|
-
class: "dn di-ns f-3 red-300") do
|
44
|
-
raw(safe "✣")
|
45
|
-
end
|
46
|
-
a(href: "http://localhost:6504",
|
47
|
-
target: "_blank",
|
48
|
-
class: "f-3 red-300 tdu tdn-ns hover-tdu-ns") do
|
49
|
-
"Local OpenTelemetry"
|
50
|
-
end
|
51
|
-
end
|
52
|
-
end
|
53
|
-
end
|
54
|
-
end
|