File tree Expand file tree Collapse file tree 5 files changed +68
-44
lines changed Expand file tree Collapse file tree 5 files changed +68
-44
lines changed Original file line number Diff line number Diff line change 1
- FROM nginx:1.15.8
2
- LABEL maintainer=
"[email protected] "
1
+ FROM node:16-alpine as builder
3
2
4
- ENV ENABLE_ENDPOINT_SELECTOR false
5
- ENV DEFAULT_SPARQL_ENDPOINT http://localhost/sparql
3
+ LABEL maintainer=
"[email protected] "
6
4
7
- COPY index.html /usr/share/nginx/html/
8
- COPY startup.sh /
9
- RUN chmod +x /startup.sh
5
+ RUN apk add bash
6
+ RUN apk add git
7
+ RUN apk add yarn
8
+ RUN mkdir /app
9
+ WORKDIR /app
10
+ RUN git clone https://github.com/TriplyDB/Yasgui.git
11
+ WORKDIR /app/Yasgui
12
+ RUN yarn install
13
+ RUN yarn run build
10
14
11
- ENTRYPOINT [ "/startup.sh" ]
15
+ FROM httpd:alpine3.19
12
16
13
- CMD ["nginx" , "-g" , "daemon off;" ]
17
+ WORKDIR /usr/local/apache2/htdocs
18
+ COPY --from=builder /app/Yasgui/build .
19
+ COPY --from=builder /app/Yasgui/packages/yasgui/static/yasgui.polyfill.min.js .
20
+ COPY --from=builder /app/Yasgui/webpack/yasgui.png .
21
+ COPY ./index-replacement.html .
22
+ COPY ./FixHostedFiles.sh /
23
+ COPY ./startup.sh /
24
+ RUN sh /FixHostedFiles.sh
25
+
26
+ ENV DEFAULT_SPARQL_ENDPOINT http://localhost:8890/sparql
27
+ ENTRYPOINT ["sh" , "/startup.sh" ]
28
+ CMD ["httpd-foreground" ]
Original file line number Diff line number Diff line change
1
+ #! /bin/sh
2
+
3
+ cd /usr/local/apache2/htdocs
4
+ rm index.html yasgui.html yasr.html yasqe.html
5
+ mv index-replacement.html index.html
6
+
Original file line number Diff line number Diff line change
1
+ <!DOCTYPE html>
2
+ < html >
3
+ < head >
4
+ < meta charset ="UTF-8 ">
5
+ < link rel ="icon " type ="image/x-icon " href ="yasgui.png ">
6
+ < style >
7
+ body {
8
+ font-family : 'Roboto' , sans-serif;
9
+ margin : 0px ;
10
+ }
11
+ </ style >
12
+ < script src ="./yasgui.polyfill.min.js "> </ script >
13
+ < link href ="https://fonts.googleapis.com/css?family=Roboto " rel ="stylesheet ">
14
+ < title > YASGUI</ title >
15
+ < link href ="/yasgui.min.css " rel ="stylesheet ">
16
+ < link href ="/yasqe.min.css " rel ="stylesheet ">
17
+ < link href ="/yasr.min.css " rel ="stylesheet ">
18
+ </ head >
19
+ < body >
20
+ < div id ="yasgui "> </ div >
21
+ < script >
22
+ window . onpageshow = function ( ) {
23
+ window . yasgui = new Yasgui ( document . getElementById ( "yasgui" ) , {
24
+ corsProxy : "" ,
25
+ requestConfig : {
26
+ endpoint : "~DEFAULT_SPARQL_ENDPOINT~" ,
27
+ }
28
+ } ) ;
29
+ } ;
30
+ </ script >
31
+ < script src ="/yasgui.min.js "> </ script >
32
+ < script src ="/yasqe.min.js "> </ script >
33
+ < script src ="/yasr.min.js "> </ script >
34
+ </ body >
35
+ </ html >
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1
- #! /bin/bash
1
+ #! /bin/sh
2
2
3
- if [ " $ENABLE_ENDPOINT_SELECTOR " == " true" ];
4
- then
5
- sed -i ' /\/\*\* endpoint-selector \*\//c\' " \/** .yasgui .endpointText {display:none !important;} *\/ \/** endpoint-selector *\/" /usr/share/nginx/html/index.html
6
- else
7
- sed -i ' /\/\*\* endpoint-selector \*\//c\' " .yasgui .endpointText {display:none !important;} \/** endpoint-selector *\/" /usr/share/nginx/html/index.html
8
- fi
9
-
10
- sed -i ' /default SPARQL endpoint/c\' " yasqe:{sparql:{endpoint:'$DEFAULT_SPARQL_ENDPOINT '}} \/\/ default SPARQL endpoint" /usr/share/nginx/html/index.html
3
+ cd /usr/local/apache2/htdocs
4
+ sed -i " s@~DEFAULT_SPARQL_ENDPOINT~@$DEFAULT_SPARQL_ENDPOINT @g" index.html
11
5
12
6
exec " $@ "
You can’t perform that action at this time.
0 commit comments