File tree Expand file tree Collapse file tree 3 files changed +26
-9
lines changed Expand file tree Collapse file tree 3 files changed +26
-9
lines changed Original file line number Diff line number Diff line change @@ -12,8 +12,9 @@ FROM alpine:latest as run
12
12
RUN apk add yt-dlp
13
13
14
14
WORKDIR /app
15
- COPY --from=build /app/dankmuzikk ./run
15
+ COPY --from=build /app/dankmuzikk ./dankmuzikk
16
+ COPY --from=build /app/run.sh ./run.sh
16
17
17
18
EXPOSE 8080
18
19
19
- CMD ["./run" , "serve " ]
20
+ CMD ["./run.sh " , "prod " ]
Original file line number Diff line number Diff line change 23
23
# dev runs the development server where it builds the tailwind css sheet,
24
24
# and compiles the project whenever a file is changed.
25
25
dev :
26
- templ generate --watch --cmd=" ./run.sh"
26
+ templ generate --watch --cmd=" ./run.sh dev "
27
27
28
28
clean :
29
29
go clean
Original file line number Diff line number Diff line change 1
1
#! /bin/sh
2
- # This script is used to compile tailwind's style sheet, and run the web server.
3
- # Also this is supposed to be ran using templ's CLI, i.e.
4
- # templ generate --watch --cmd="./run.sh"
5
- # idk, that's it.
6
2
7
- go generate
8
- go run . serve
3
+ dev () {
4
+ # This function is used to compile tailwind's style sheet, and run the web server.
5
+ # Also this is supposed to be ran using templ's CLI, i.e.
6
+ # templ generate --watch --cmd="./run.sh"
7
+ # idk, that's it.
8
+
9
+ go generate
10
+ go run . serve
11
+ }
12
+
13
+ prod () {
14
+ ./dankmuzikk migrate
15
+ ./dankmuzikk serve
16
+ }
17
+
18
+ if [ $1 == " dev" ]; then
19
+ dev
20
+ fi
21
+
22
+ if [ $1 == " prod" ]; then
23
+ prod
24
+ fi
You can’t perform that action at this time.
0 commit comments