Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
monitor
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Dorian Koch
monitor
Commits
097b5818
Verified
Commit
097b5818
authored
6 months ago
by
Dorian Koch
Browse files
Options
Downloads
Patches
Plain Diff
Add webserver
parent
b571c624
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
Dockerfile
+3
-2
3 additions, 2 deletions
Dockerfile
docker-compose.yml
+22
-1
22 additions, 1 deletion
docker-compose.yml
run_visualize_webserver.sh
+9
-0
9 additions, 0 deletions
run_visualize_webserver.sh
with
34 additions
and
3 deletions
Dockerfile
+
3
−
2
View file @
097b5818
...
...
@@ -8,8 +8,9 @@ RUN apt-get update \
COPY
requirements.txt .
RUN
pip
install
--no-cache-dir
-r
requirements.txt
COPY
wait-for-it.sh .
RUN
chmod
+x wait-for-it.sh
COPY
*.html .
COPY
*.sh .
RUN
chmod
+x
*
.sh
COPY
*.py .
CMD
["python", "main.py"]
This diff is collapsed.
Click to expand it.
docker-compose.yml
+
22
−
1
View file @
097b5818
services
:
monitor
:
build
:
.
init
:
true
...
...
@@ -13,6 +12,28 @@ services:
-
postgres
command
:
[
"
./wait-for-it.sh"
,
"
postgres:5432"
,
"
--"
,
"
python"
,
"
main.py"
]
visualize
:
build
:
.
init
:
true
restart
:
unless-stopped
environment
:
-
DB_HOST=postgres
-
DB_NAME=response_times
-
DB_USER=myuser
-
DB_PASSWORD=mypassword
depends_on
:
-
postgres
-
monitor
ports
:
-
12923:12923
command
:
[
"
./wait-for-it.sh"
,
"
postgres:5432"
,
"
--"
,
"
./run_visualize_webserver.sh"
,
]
postgres
:
image
:
postgres:13
restart
:
unless-stopped
...
...
This diff is collapsed.
Click to expand it.
run_visualize_webserver.sh
0 → 100644
+
9
−
0
View file @
097b5818
#!/usr/bin/env bash
python export.py
>
exported.csv
mkdir
-p
/var/www/html
mv
exported.csv /var/www/html
cp
visualize.html /var/www/html
cd
/var/www/html
python3
-m
http.server 12923
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment