Skip to content

Commit 510e31f

Browse files
BrainIsDeadMykhailo Istomin
and
Mykhailo Istomin
authored
deleted *.php from /server and docs, deleted Dockerfile (#1092)
* deleted *.php from /server and docs, deleted Dockerfile Co-authored-by: Mykhailo Istomin <[email protected]>
1 parent 4e64d16 commit 510e31f

File tree

12 files changed

+5
-3093
lines changed

12 files changed

+5
-3093
lines changed

deploy.json

-15
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,6 @@
6565
"dst": "[[package]]/acquisition/cdcp/",
6666
"match": "^.*\\.(py)$",
6767
"add-header-comment": true
68-
},{
69-
"type": "move",
70-
"src": "src/acquisition/cdcp/cdc_upload.php",
71-
"dst": "[[auto_web]]/cdc_upload/index.php",
72-
"add-header-comment": true
7368
},
7469

7570
"// acquisition - ght",
@@ -107,16 +102,6 @@
107102
"dst": "[[package]]/acquisition/wiki/",
108103
"match": "^.*\\.(py)$",
109104
"add-header-comment": true
110-
},{
111-
"type": "move",
112-
"src": "src/acquisition/wiki/master.php",
113-
"dst": "[[auto_web]]/wiki/master.php",
114-
"add-header-comment": true
115-
},{
116-
"type": "move",
117-
"src": "src/acquisition/wiki/dashboard.php",
118-
"dst": "[[auto_web]]/wiki/index.php",
119-
"add-header-comment": true
120105
},
121106

122107
"// acquisition - flusurv",

dev/docker/web/epidata/Dockerfile

-11
This file was deleted.

dev/docker/web/epidata/README.md

-22
This file was deleted.

dev/docker/web/epidata/assets/database_config.php

-7
This file was deleted.

docs/epidata_development.md

+3-39
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ above. The base images are built first, followed by the derived
116116
`epidata`-specific images.
117117

118118
- The [`delphi_web_epidata` image](https://github.com/cmu-delphi/delphi-epidata/blob/main/dev/docker/web/epidata/README.md) adds
119-
the Epidata API to the `delphi_web` image.
119+
the Epidata API to the `delphi_web_epidata` image.
120120
- The
121121
[`delphi_database_epidata` image](https://github.com/cmu-delphi/delphi-epidata/blob/main/dev/docker/database/epidata/README.md)
122122
adds user accounts, `epidata` & other appropriate databases, and relevant tables
@@ -125,14 +125,8 @@ above. The base images are built first, followed by the derived
125125
From the root of your workspace, all of the images can be built as follows:
126126

127127
```bash
128-
docker build -t delphi_web \
129-
-f repos/delphi/operations/dev/docker/web/Dockerfile .
130-
131-
docker build -t delphi_web_epidata \
132-
-f repos/delphi/delphi-epidata/dev/docker/web/epidata/Dockerfile .
133-
134-
docker build -t delphi_database \
135-
-f repos/delphi/operations/dev/docker/database/Dockerfile .
128+
docker build -t delphi_web_epidata\
129+
-f ./devops/Dockerfile .;\
136130

137131
docker build -t delphi_database_epidata \
138132
-f repos/delphi/delphi-epidata/dev/docker/database/epidata/Dockerfile .
@@ -394,33 +388,3 @@ The command above maps two local directories into the container:
394388
- `/repos/delphi/delphi-epidata/src`: Just the source code, which forms the
395389
container's `delphi.epidata` python package.
396390

397-
### server code
398-
399-
Local web sources (e.g. PHP files) can be bind-mounted into a
400-
`delphi_web_epidata` container as follows:
401-
402-
```bash
403-
docker run --rm -p 127.0.0.1:10080:80 \
404-
--mount type=bind,source="$(pwd)"/repos/delphi/delphi-epidata/src/server/api.php,target=/var/www/html/epidata/api.php,readonly \
405-
--mount type=bind,source="$(pwd)"/repos/delphi/delphi-epidata/src/server/api_helpers.php,target=/var/www/html/epidata/api_helpers.php,readonly \
406-
--network delphi-net --name delphi_web_epidata \
407-
delphi_web_epidata
408-
```
409-
410-
The command above mounts two specific files into the image. It may be tempting
411-
to bind mount the `src/server` directory rather than specific files, however
412-
that is currently problematic for a couple of reasons:
413-
414-
1. `server/.htaccess` [from the local repository](https://github.com/cmu-delphi/delphi-epidata/blob/main/src/server/.htaccess) uses
415-
the `Header` directive. However, the webserver in the container doesn't have
416-
the corresponding module enabled. This causes the server to deny access to
417-
the API.
418-
2. `server/database_config.php`
419-
[in the image](https://github.com/cmu-delphi/delphi-epidata/blob/main/dev/docker/web/epidata/assets/database_config.php) contains
420-
database credentials for use in conjunction with the
421-
`delphi_database_epidata` container during development. However, the same
422-
file from [the local repository](https://github.com/cmu-delphi/delphi-epidata/blob/main/src/server/database_config.php) only
423-
contains placeholder values. This prevents communication with the database.
424-
425-
There is currently no benefit to bind-mounting sources into the database
426-
container because schema changes require restarting the container anyway.

docs/new_endpoint_tutorial.md

+2-4
Original file line numberDiff line numberDiff line change
@@ -273,10 +273,8 @@ already built the `delphi_python` image above:
273273

274274
```bash
275275
# build web and database images for epidata
276-
docker build -t delphi_web \
277-
-f repos/delphi/operations/dev/docker/web/Dockerfile .
278-
docker build -t delphi_web_epidata \
279-
-f repos/delphi/delphi-epidata/dev/docker/web/epidata/Dockerfile .
276+
docker build -t delphi_web_epidata\
277+
-f ./devops/Dockerfile .;\
280278
docker build -t delphi_database_epidata \
281279
-f repos/delphi/delphi-epidata/dev/docker/database/epidata/Dockerfile .
282280

src/acquisition/cdcp/cdc_upload.php

-101
This file was deleted.

0 commit comments

Comments
 (0)