Skip to content

Commit 61528f1

Browse files
committed
Update Blog “open-sourcing-workshops-on-demand-part-5-create-a-workshop”
1 parent 890881f commit 61528f1

File tree

1 file changed

+80
-16
lines changed

1 file changed

+80
-16
lines changed

content/blog/open-sourcing-workshops-on-demand-part-5-create-a-workshop.md

Lines changed: 80 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -35,22 +35,26 @@ As an admin of the Workshops-on-demand infrastructure, I had to perform sever
3535

3636
1. ###### Test and validate installation of the new kernel on the staging backend server by:
3737

38-
* Creating a new branch for this test
38+
* * Creating a new branch for this test
39+
40+
<!---->
41+
3942
* Modifying the [backend server installation yaml file ](https://github.com/Workshops-on-Demand/wod-backend/blob/main/ansible/install_backend.yml#L326)to include the new kernel.
4043

4144
![](/img/wod-go-yml1.png)
4245

4346
![](/img/wod-go-yaml2.png)
44-
* Validating the changes by testing a new backend install process.
45-
* Pushing the changes to the github repo.
47+
48+
* Validating the changes by testing a new backend install process.
49+
* Pushing the changes to the github repo.
4650

4751
2. ###### Creating a user for the workshop developer on the test/dev and staging backend servers.
4852
3. ###### Providing to the developer the necessary information to connect to the test/dev and staging backend servers.
4953
4. ###### Copy over the workshop developer's home folder a workshop template containing examples of introduction, conclusion and lab notebooks, allowing him to start his work.
5054

5155
##### On the database server:
5256

53-
In order to exist, a workshop requires serveral things:
57+
In order to exist, a workshop requires serveral entries in the database:
5458

5559
In the **Workshops table:**
5660

@@ -102,6 +106,39 @@ A new entry will need the following:
102106
* **WorkshopId:** Id of the workshop linked to the video.
103107
* **Active:** Tag to set to enable visibility of the replay in registration portal.
104108

109+
one could create these entries manually or leverage a simple wod.yml fiel containing them and that can be later parsed in order to feed the database with the relevant info, quite handy,no ?
110+
111+
Here is an exampe of such a file:
112+
113+
```
114+
%YAML 1.1
115+
# Meta data for the GO101 Workshop to populate seeder
116+
---
117+
name: 'GO 101 - A simple introduction to Go Programming Language'
118+
notebook: 'WKSHP-GO101'
119+
description: 'Go, also called Golang or Go language, is an open source programming language that Google developed. Software developers use Go in an array of operating systems and frameworks to develop web applications, cloud and networking services, and other types of software. This workshop will drive you through the basics of this programming language.'
120+
active: false
121+
capacity: 20
122+
priority: 1
123+
range: [151-170]
124+
reset: false
125+
ldap: false
126+
location: 'mougins'
127+
replayId: 31
128+
varpass: false
129+
compile: false
130+
workshopImg: 'https://us-central1-grommet-designer.cloudfunctions.net/images/frederic-passeron-hpe-com/WOD-GO-101-A-simp-introduction-to-Go-programming-language.jpeg'
131+
badgeImg: 'https://us-central1-grommet-designer.cloudfunctions.net/images/frederic-passeron-hpe-com/go101-a-simple-introduction-to-go-programming-language.jpg'
132+
beta: false
133+
category: 'Open Source'
134+
duration: 4
135+
alternateLocation: 'grenoble'
136+
presenter: 'Matthew Doddler'
137+
role: 'FullStack developer'
138+
avatar: '/img/SpeakerImages/MattD.jpg'
139+
videoLink: 'https://hpe-developer-portal.s3.amazonaws.com/Workshops-on-Demand-Coming-Soon-Replay.mp4'
140+
```
141+
105142
As the developer of the Workshops-on-demand content, Matt had to perform several tasks:
106143

107144
##### On the backend server:
@@ -126,12 +163,6 @@ As an admin, I need to check the pull request and accept it. Once done, the t
126163

127164
The very same processes will apply to the move to production phase.
128165

129-
130-
131-
* Modifying the \[backend server installation yaml file ]
132-
133-
134-
135166
# Complex workshop example:
136167

137168
II will not repeat the steps I descirbed earlier for the simple workshop example. I will focus here on the specific aspects related to this new workshop. Are you familiar with High Performance Computing (HPC)? I am not. Even tough I am surrounded by some experts in that field in the HPE Grenoble Office. Let's consider that one of these colleagues is willing to build up a dedicated workshop on HPC Stax. As usual, we will start by a meeting each of us will explain to the other his goals, and how to achieve them. Once I get a clearer understanding of the technology involved, he and I can move on figure out the best platform to run his woorkshop on.
@@ -142,22 +173,55 @@ As an admin of the Workshops-on-demand infrastructure, I had to perform sever
142173

143174
the workshop will require:
144175

145-
* A dedicated server running docker to host the student containers in which the workshops' labs will take place.
176+
* A dedicated server running docker to host the student containers in which the workshops' labs will take place.
177+
178+
* This means preparing a server (VM or physical) : We will consider it as an appliance.
179+
* Updating the relevant variable file to associate the IP address of the server to the workshop (there could be multiple servers too associated to a given workshop)
180+
* A set of scripts under wod-backend/scripts or wod-private/scripts folders depending on the nature of the workshop to manage the workshop's lifecycle.
181+
182+
* Some generic scripts applying to all workshops' appliances : general setup phase setting up common requirements for any appliance (student users creation, ssh keys, etc..) up to some specific ones dedicated to a given workshop.
183+
184+
* create-appliance.sh (ssh keys, ldap setup)
185+
* setup-appliance.sh \[WKSHP-NAME] (Student setup, Appliance Setup, Workshop setup) calls:
146186

147-
* A set of Ansible playbooks to setup the dedicated server.
187+
* setup-globalappliance.sh (global / generic setup)
188+
* setup-\[WKSHP-NAME].sh (Prepare appliance with workshop's reqs, Docker image for instance)
189+
* create-\[WKSHP-NAME].sh (called at deployement time to instantiate the necessary appliance(s) requiered by the workshop
190+
* reset-appliance (reset ssh keys and students credentials on appliance
191+
* cleanup-\[WKSHP-NAME].sh (takes care of cleanup some workshop's specifics)
192+
* reset-\[WKSHP-NAME].sh (reset of the workshop's appliance, docker compose down of a container for instance)
193+
* A set of variables to be leveraged by the notebooks. These variables are to be set in yml format. They will be parsed at deployment times to set student ids, appliance IP addresses, and other relevant parameters like ports, simulated hardware information for instance.
148194

149-
* A set of scripts to manage the workshop's lifecycle.
150195

151-
* A set of variables to be leveraged by the notebooks.
152196

197+
Whenever all the scripts are functional and that the necessary actions have been performed both on backend and frontend servers, some functional tests can conducted using cli and later webui.
153198

199+
* From the cli on the jupyterhub server:
154200

201+
* one can leverage the wod-test-action.sh script to test a workshop lifecycle action from deployment (CREATE) to cleanup, rest or purge.
155202

203+
```
204+
dev@dev3:~$ wod-test-action.sh
205+
Syntax: wod-test-action.sh <CREATE|CLEANUP|RESET|PURGE|PDF|WORD> WKSHOP [MIN[,MAX]
206+
ACTION is mandatory
207+
```
208+
* The available trace under ~/.mail/from will detail the different steps of the action and allow you to troubelshoot any issue.
156209
157210
A set of notebooks that will be used by the student to follow instructions cells in markdown and run code cells leveraging the relevant kernel. If you are not familiar with Jupyter notebooks, a simple [101 workshop](https://developer.hpe.com/hackshack/workshop/25) is available in our Workshops-on-Demand 's catalog.
158211
159-
Optional:
212+
A workshop should come up with at least :
213+
214+
* 0-ReadMeFirst.ipynb
215+
* 1-WKSHP-LAB1.ipynb
216+
* 2-WKSHP-LAB2.ipynb
217+
* 3-WKSHP-Conclusion.ipynb
218+
* LICENCE.MD
219+
* A pictures folder (if any screenshot is required in lab instructions)
220+
* A README.md (0-ReadMeFirst.ipynb in md format)
221+
* wod.yml ( for database injection)
222+
223+
224+
160225
161-
You should now have a better understanding of the maintenance tasks associated to the backend server. Similar actions are available for the other components of the project. Checking tasks have been created for the frontend and api-db server. Having now mostly covered all the subjects related to the backend server from an infrastructure standpoint, it is high time to discuss the content part. In my next blog, I plan to describe the workshop creation process. Time to understand how to build up some content for the JupyterHub server!
162226
163227
If we can be of any help in clarifying any of this, please reach out to us on [Slack](https://slack.hpedev.io/). Please be sure to check back at [HPE DEV](https://developer.hpe.com/blog) for a follow up on this. Also, don't forget to check out also the Hack Shack for new [workshops](https://developer.hpe.com/hackshack/workshops)! Willing to collaborate with us? Contact us so we can build more workshops!

0 commit comments

Comments
 (0)