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: lab1.md
+26Lines changed: 26 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -64,6 +64,32 @@ $ faas-cli help
64
64
$ faas-cli version
65
65
```
66
66
67
+
## Configure a registry - The Docker Hub
68
+
69
+
Sign up for a Docker Hub account. The [Docker Hub](https://hub.docker.com) allows you to publish your Docker images on the Internet for use on multi-node clusters or to share with the wider community. We will be using the Docker Hub to publish our functions during the workshop.
70
+
71
+
You can sign up here: [Docker Hub](https://hub.docker.com)
72
+
73
+
Open a Terminal or Git Bash window and log into the Docker Hub using the username you signed up for above.
74
+
75
+
```
76
+
$ docker login
77
+
```
78
+
79
+
> Note: Tip from community - if you get an error while trying to run this command on a Windows machine, then click on the Docker for Windows icon in the taskbar and log into Docker there instead "Sign in / Create Docker ID".
80
+
81
+
* Set your OpenFaaS prefix for new images
82
+
83
+
OpenFaaS images are stored in a Docker registry or the Docker Hub, we can set an environment variable so that your username is automatically added to new functions you create. This will save you some time over the course of the workshop.
84
+
85
+
Edit `~/.bashrc` or `~/.bash_profile` - create the file if it doesn't exist.
86
+
87
+
Now add the following - changing the URL as per the one you saw above.
88
+
89
+
```
90
+
export OPENFAAS_PREFIX="" # Populate with your Docker Hub username
91
+
```
92
+
67
93
### Setup a single-node cluster
68
94
69
95
If you're taking part in an instructor-lead event then the organiser may ask you to use Docker Swarm, because it's much quicker and easier to set up in a short period of time. For some workshops you will be using Kubernetes.
Copy file name to clipboardExpand all lines: lab1a.md
-16Lines changed: 0 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,22 +14,6 @@ $ docker swarm init
14
14
15
15
> If you receive an error then pass the `--advertise-addr` parameter along with your laptop's IP address.
16
16
17
-
### Docker Hub
18
-
19
-
Sign up for a Docker Hub account. The [Docker Hub](https://hub.docker.com) allows you to publish your Docker images on the Internet for use on multi-node clusters or to share with the wider community. We will be using the Docker Hub to publish our functions during the workshop.
20
-
21
-
You can sign up here: [Docker Hub](https://hub.docker.com)
22
-
23
-
> Note: The Docker Hub can also be setup to automate builds of Docker images.
24
-
25
-
Open a Terminal or Git Bash window and log into the Docker Hub using the username you signed up for above.
26
-
27
-
```sh
28
-
$ docker login
29
-
```
30
-
31
-
> Note: Tip from community - if you get an error while trying to run this command on a Windows machine, then click on the Docker for Windows icon in the taskbar and log into Docker there instead "Sign in / Create Docker ID".
32
-
33
17
### Deploy OpenFaaS
34
18
35
19
The instructions for deploying OpenFaaS change from time to time as we strive to make this easier. The following will get OpenFaaS deployed in around 60 seconds:
Sign up for a Docker Hub account. The [Docker Hub](https://hub.docker.com) allows you to publish your Docker images on the Internet for use on multi-node clusters or to share with the wider community. We will be using the Docker Hub to publish our functions during the workshop.
210
-
211
-
You can sign up here: [Docker Hub](https://hub.docker.com)
212
-
213
-
Open a Terminal or Git Bash window and log into the Docker Hub using the username you signed up for above.
214
-
215
-
```
216
-
$ docker login
217
-
```
218
-
219
-
> Note: Tip from community - if you get an error while trying to run this command on a Windows machine, then click on the Docker for Windows icon in the taskbar and log into Docker there instead "Sign in / Create Docker ID".
220
-
221
207
## Deploy OpenFaaS
222
208
223
209
The instructions for deploying OpenFaaS change from time to time as we strive to make this even easier.
@@ -308,7 +294,7 @@ Edit `~/.bashrc` or `~/.bash_profile` - create the file if it doesn't exist.
308
294
Now add the following - changing the URL as per the one you saw above.
0 commit comments