Skip to content

Commit 372a76d

Browse files
authored
fix: resolve missing stylesheets and WSGI 404 errors
1 parent b878e52 commit 372a76d

7 files changed

Lines changed: 27 additions & 10 deletions

File tree

docker/Dockerfile

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,13 @@ RUN pip3 install --no-cache-dir --break-system-packages \
1515
# Copy static x0 config files into the web-server document root
1616
COPY static/ /var/www/vhosts/x0/static/github2sf/
1717

18+
# Link the x0 base stylesheets and fontawesome into the app subdir so that
19+
# the x0 framework can find bootstrap.css, globalstyles.css and all.min.css
20+
# at the {subdir}/ path it generates in the HTML <link> tags.
21+
RUN ln -s /var/www/vhosts/x0/static/bootstrap.css /var/www/vhosts/x0/static/github2sf/bootstrap.css \
22+
&& ln -s /var/www/vhosts/x0/static/globalstyles.css /var/www/vhosts/x0/static/github2sf/globalstyles.css \
23+
&& ln -s /var/www/vhosts/x0/static/fontawesome /var/www/vhosts/x0/static/github2sf/fontawesome
24+
1825
# Copy Python WSGI backend scripts into the x0 python directory
1926
COPY python/ /var/www/vhosts/x0/python/github2sf/
2027

python/CreateStackfieldTask.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,12 @@
1111
import sys
1212
import json
1313

14+
sys.path.insert(0, '/var/www/vhosts/x0/python/github2sf')
15+
1416
import POSTData
1517
from StdoutLogger import logger
1618

17-
from router import ServiceRouter
19+
from microesb.router import ServiceRouter
1820

1921

2022
def application(environ, start_response):

python/GetGitHubIssueDetails.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,12 @@
1111
import sys
1212
import json
1313

14+
sys.path.insert(0, '/var/www/vhosts/x0/python/github2sf')
15+
1416
import POSTData
1517
from StdoutLogger import logger
1618

17-
from router import ServiceRouter
19+
from microesb.router import ServiceRouter
1820

1921

2022
def application(environ, start_response):

python/SearchGitHubIssues.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,12 @@
1111
import sys
1212
import json
1313

14+
sys.path.insert(0, '/var/www/vhosts/x0/python/github2sf')
15+
1416
import POSTData
1517
from StdoutLogger import logger
1618

17-
from router import ServiceRouter
19+
from microesb.router import ServiceRouter
1820

1921

2022
def application(environ, start_response):

python/VerifyGitHubCredentials.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,12 @@
1010
import sys
1111
import json
1212

13+
sys.path.insert(0, '/var/www/vhosts/x0/python/github2sf')
14+
1315
import POSTData
1416
from StdoutLogger import logger
1517

16-
from router import ServiceRouter
18+
from microesb.router import ServiceRouter
1719

1820

1921
def application(environ, start_response):

python/VerifyStackfieldCredentials.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,12 @@
1010
import sys
1111
import json
1212

13+
sys.path.insert(0, '/var/www/vhosts/x0/python/github2sf')
14+
1315
import POSTData
1416
from StdoutLogger import logger
1517

16-
from router import ServiceRouter
18+
from microesb.router import ServiceRouter
1719

1820

1921
def application(environ, start_response):

static/object.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@
122122
"TextID": "TXT.SCREEN1.GITHUB.VERIFY.BUTTON",
123123
"Style": "btn btn-outline-primary w-100 mb-4",
124124
"IconStyle": "fa-solid fa-shield-halved",
125-
"OnClick": "/python/VerifyGitHubCredentials.py",
125+
"OnClick": "/python/github2sf/VerifyGitHubCredentials.py",
126126
"SrcDataObjects":
127127
[
128128
"GitHubCredentialsForm"
@@ -225,7 +225,7 @@
225225
"TextID": "TXT.SCREEN1.STACKFIELD.VERIFY.BUTTON",
226226
"Style": "btn btn-outline-success w-100 mb-4",
227227
"IconStyle": "fa-solid fa-shield-halved",
228-
"OnClick": "/python/VerifyStackfieldCredentials.py",
228+
"OnClick": "/python/github2sf/VerifyStackfieldCredentials.py",
229229
"SrcDataObjects":
230230
[
231231
"StackfieldCredentialsForm"
@@ -340,7 +340,7 @@
340340
"OnEvent":
341341
{
342342
"Events": [ "SearchGitHubIssues" ],
343-
"ServiceCall": "/python/SearchGitHubIssues.py"
343+
"ServiceCall": "/python/github2sf/SearchGitHubIssues.py"
344344
},
345345
"SrcDataObjects":
346346
{
@@ -426,7 +426,7 @@
426426
"OnEvent":
427427
{
428428
"Events": [ "ConnectStackfieldTask" ],
429-
"ServiceCall": "/python/GetGitHubIssueDetails.py"
429+
"ServiceCall": "/python/github2sf/GetGitHubIssueDetails.py"
430430
},
431431
"SrcDataObjects":
432432
{
@@ -755,7 +755,7 @@
755755
"TextID": "TXT.SCREEN3.CREATE.BUTTON",
756756
"Style": "btn btn-success w-100 mt-2 mb-4",
757757
"IconStyle": "fa-solid fa-circle-plus",
758-
"OnClick": "/python/CreateStackfieldTask.py",
758+
"OnClick": "/python/github2sf/CreateStackfieldTask.py",
759759
"SrcDataObjects":
760760
[
761761
"IssueDetailsForm",

0 commit comments

Comments
 (0)