You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: examples/chem-sync-local-flask/README.md
+35-13Lines changed: 35 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,6 +24,12 @@ Create an empty placeholder file for Docker secrets. *nix example:
24
24
touch .client_secret
25
25
```
26
26
27
+
Windows example:
28
+
29
+
```cmd
30
+
echo.> .client_secret
31
+
```
32
+
27
33
Start Docker:
28
34
29
35
```bash
@@ -32,6 +38,11 @@ docker compose up --build -d
32
38
33
39
Tip: You can omit the `-d` option if you want to run in the foreground. Otherwise, use `docker compose logs -f` to tail logs.
34
40
41
+
> ℹ️ **Windows Note 1:** "Use ContainerD for pulling and storing images" may need to be enabled in `Docker > Settings > Features in development > Beta Features`
42
+
43
+
> ℹ️ **Windows Note 2**: If running into an error like "ERROR: request returned Bad Gateway for API route and version", [this solution](https://github.com/docker/for-mac/issues/6956#issuecomment-1876444658) may fix the problem.
44
+
45
+
35
46
You can verify that Flask is up and running:
36
47
37
48
```bash
@@ -101,19 +112,6 @@ Generate a client secret in Benchling and be sure to copy the secret.
101
112
102
113

103
114
104
-
One easy way to set these environment variables for Docker is to add a `.env` file.
105
-
106
-
```bash
107
-
touch .env
108
-
```
109
-
110
-
Open it in an editor of your choice and set the values with the plaintext client ID
111
-
for your App. For example:
112
-
113
-
```
114
-
CLIENT_ID=42a0cd39-0543-4dd2-af02-a866c97f0c4d
115
-
```
116
-
117
115
Since the client secret is sensitive, it's handled a bit differently. It's
118
116
registered as a `secret` in our `docker-compose.yaml` file, which will be looking
119
117
for a file `./client_secret`.
@@ -130,6 +128,30 @@ pbpaste > .client_secret
130
128
131
129
You'll then need to restart _just_ the `benchling-app` Docker service to pick up the changes:
132
130
131
+
### Setting Client ID
132
+
133
+
Our App needs a Client ID to pair with the Client Secret for authentication to Benchling. In this case, we've created our
134
+
App to accept `CLIENT_ID` as an environment variable.
135
+
136
+
One easy way to set an environment variables for Docker is to add a `.env` file.
137
+
138
+
```bash
139
+
touch .env
140
+
```
141
+
142
+
Windows example:
143
+
144
+
```cmd
145
+
echo.> .env
146
+
```
147
+
148
+
Open it in an editor of your choice and set the values with the plaintext client ID
0 commit comments