Skip to content

Commit 9f2a0e3

Browse files
Merge pull request #58 from docusign/dockerize
dockerize
2 parents 4ca2689 + a8e87a5 commit 9f2a0e3

File tree

130 files changed

+12370
-20777
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

130 files changed

+12370
-20777
lines changed

.env renamed to .env_example

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,4 @@ DS_AUTH_SERVER=https://account-d.docusign.com
3131

3232
# Demo Docusign API URL
3333
REACT_APP_DS_DEMO_SERVER=https://demo.docusign.net
34-
REACT_APP_DS_CLICKWRAP_URL=//demo.docusign.net/clickapi/sdk/latest/docusign-click.js
34+
REACT_APP_DS_CLICKWRAP_URL=https://demo.docusign.net/clickapi/sdk/latest/docusign-click.js

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
*.pyc
22
.idea
3-
.env
43

4+
.env
55
__pycache__/
66

77
# pyenv

app/api/clickwrap.py

Lines changed: 0 additions & 29 deletions
This file was deleted.

app/ds_client.py

Lines changed: 0 additions & 164 deletions
This file was deleted.

client/Dockerfile

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
FROM --platform=linux/amd64 node:20.14 AS base
2+
3+
ARG REACT_APP_API_BASE_URL
4+
ENV REACT_APP_API_BASE_URL=$REACT_APP_API_BASE_URL
5+
6+
WORKDIR /app
7+
COPY .env ./
8+
COPY ./client/package.json ./client/yarn.lock ./
9+
RUN npm install
10+
11+
COPY ./client/ .
12+
13+
RUN npm run build
14+
15+
# Run stage
16+
FROM --platform=linux/amd64 nginx:1.23-alpine
17+
COPY --from=base /app/build /var/www/app
18+
COPY ./client/nginx/conf/ /etc/nginx/conf.d
19+
EXPOSE 80 443

client/nginx/conf/default.conf

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
server {
2+
listen 80;
3+
listen 443;
4+
5+
server_tokens off;
6+
7+
root /var/www/app;
8+
location / {
9+
autoindex on;
10+
autoindex_exact_size off;
11+
try_files $uri /index.html;
12+
}
13+
14+
location /api {
15+
# rewrite ^/api(/.+) /$1 break;
16+
# rewrite "^/api/(.*)$" /$1 break;
17+
18+
proxy_set_header X-Real-IP $remote_addr;
19+
proxy_set_header X-Real-Port $remote_port;
20+
proxy_set_header Host $http_host;
21+
proxy_connect_timeout 3000;
22+
proxy_send_timeout 3000;
23+
proxy_read_timeout 3000;
24+
proxy_pass http://backend:5001;
25+
}
26+
}
27+

package.json renamed to client/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"version": "0.1.0",
44
"private": true,
55
"dependencies": {
6-
"@popperjs/core": "^2.11.8",
6+
"popper.js": "^1.16.1",
77
"@testing-library/jest-dom": "^5.17.0",
88
"@testing-library/react": "^14.3.1",
99
"@testing-library/user-event": "^14.5.2",

client/public/MyUni_OG.png

10.3 KB
Loading

0 commit comments

Comments
 (0)