Skip to content

Commit

Permalink
Merge branch 'master' into typo-fix
Browse files Browse the repository at this point in the history
  • Loading branch information
johanvdw authored Dec 19, 2023
2 parents 622ad62 + 9595247 commit 7398715
Show file tree
Hide file tree
Showing 5 changed files with 35 additions and 54 deletions.
17 changes: 12 additions & 5 deletions deployment/playbook/roles/fosdem_volunteers/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@
name: "{{item}}"
state: present
with_items:
- python
- nginx
- virtualenv
- python3-venv
- name: "Create system user {{app_user}}"
user:
name: "{{app_user}}"
Expand All @@ -20,15 +19,13 @@
repo: https://github.com/FOSDEM/volunteers.git
dest: "{{base_dir}}/tool"
version: master
become: yes
become_user: "{{app_user}}"
register: app_updated
notify: Restart fosdem_volunteers
- name: Install dependencies inside a virtual environment
pip:
virtualenv: "{{base_dir}}/venv3"
virtualenv_python: python3
requirements: "{{base_dir}}/tool/requirements.txt"
requirements: "{{base_dir}}/tool/requirements-frozen.txt"
become: yes
become_user: "{{app_user}}"
- name: Add gunicorn to venv
Expand Down Expand Up @@ -62,6 +59,16 @@
- migrate
- collectstatic
when: app_updated.changed
- name: install the tmpfiles.d conf
become: true
copy:
content: d /run/volunteers 0755 {{ app_user }} {{ app_user }} - -
dest: /usr/lib/tmpfiles.d/fosdem_volunteers.conf

- name: configure tmpfiles.d
become: true
command: systemd-tmpfiles --create

- name: Create systemd service file
template:
dest: /etc/systemd/system/fosdem_volunteers.service
Expand Down
49 changes: 18 additions & 31 deletions volunteers/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,37 +144,24 @@ def sync_with_penta(cls):
rooms = day.findall('room')
for room in rooms:
room_name = room.get('name')
if edition.digital_edition:
needs_hosting = False
if room_name.startswith('S'):
# skip import of stands
continue
if room_name[0] in ['L', 'M'] or room_name in ["D.blockchain"]:
needs_hosting = True
events = room.findall('event')
for event in events:
talk = Talk.penta_create_or_update(event, edition, day_date)
if needs_hosting:
Task.create_or_update_from_talk(edition, talk, 'Hosting', [1, 2, 3])
else:
# Lightning talks are done manually since the time slots are so small.
needs_heralding = False
needs_video = False

if room_name in ['Janson', 'K.1.105 (La Fontaine)']:
needs_heralding = True
needs_video = getattr(settings, 'IMPORT_VIDEO_TASKS', True)

events = room.findall('event')
for event in events:
talk = Talk.penta_create_or_update(event, edition, day_date)
######################
# Tasks, if required #
######################
if needs_heralding:
Task.create_or_update_from_talk(edition, talk, 'Heralding', [3, 2, 5])
if needs_video:
Task.create_or_update_from_talk(edition, talk, 'Video', [1, 1, 1])
# Lightning talks are done manually since the time slots are so small.
needs_heralding = False
needs_video = False

if room_name in ['Janson', 'K.1.105 (La Fontaine)']:
needs_heralding = True
needs_video = getattr(settings, 'IMPORT_VIDEO_TASKS', True)

events = room.findall('event')
for event in events:
talk = Talk.penta_create_or_update(event, edition, day_date)
######################
# Tasks, if required #
######################
if needs_heralding:
Task.create_or_update_from_talk(edition, talk, 'Heralding', [3, 2, 5])
if needs_video:
Task.create_or_update_from_talk(edition, talk, 'Video', [1, 1, 1])


"""
Expand Down
9 changes: 5 additions & 4 deletions volunteers/templates/static/promo.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ <h2 class="intro"><span>FOSDEM</span><br/>Volunteering</h2>
</li>

<li><h3>Location</h3>
<p>FOSDEM 2023 will be returning to the ULB in Brussels, Belgium, while continuing to offer an online presence.</p>
<p>FOSDEM 2024 will be returning to the ULB in Brussels, Belgium, while continuing to offer an online presence.</p>
</li>

<li><h3>Volunteering</h3>
Expand All @@ -36,16 +36,17 @@ <h2 class="intro"><span>FOSDEM</span><br/>Volunteering</h2>
<p>Real time chat is bridged between matrix and irc:
<ul>
<li><a href='https://matrix.to/#/#volunteers:fosdem.org'>#fosdem-volunteers</a> on matrix (<a href='https://chat.fosdem.org/#/room/#volunteers:fosdem.org'>webchat</a>)</li>
<li><a href="irc://irc.libera.chat/fosdem-volunteers">#fosdem-volunteers</a> (<a href="https://web.libera.chat/#fosdem-volunteers">webchat</a>) on <a href="https://irc.libera.chat/">libera chat</a></li>
</ul>
</p>
</li>

<li><h3>Real People</h3>
<p><strong>Pieter De Praetere</strong></p>
<p><a href="mailto:pieter@fosdem.org">pieter@fosdem.org</a></p>
<p><a href="mailto:pieter@fosdem.org">Send Pieter an email</a></p>
<p><strong>Kristian Schuhmacher</strong></p>
<p><a href="mailto:kristian@fosdem.org">kristian@fosdem.org</a></p>
<p><a href="mailto:kristian@fosdem.org">Send Kristian an email</a></p>
<p><strong>Dan Clark</strong></p>
<p><a href="mailto:dan@fosdem.org">Send Dan an email</a></p>
</li>
</ul>
{% endblock %}
9 changes: 0 additions & 9 deletions volunteers/templates/volunteers/tasks.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,6 @@

{% block content %}

{#{% if user.is_authenticated and not user_in_penta %}
<p class="faq">
<h3>Register in pentabarf!</h3>
Please register an account in <a href="https://penta.fosdem.org/submission">pentabarf</a> and add it to <a href="/volunteers/{{ user.username }}/edit/">your details</a> to enable hosting talks.
<br />
</p>

{% endif %}
#}
{% if user.is_authenticated %}<a class="larger-font" href="{% url 'task_list_detailed' user.username %}" title="View schedule">View your schedule</a>{% endif %}

<form class="task_list" action="{% url 'task_list' %}" method="post">{% csrf_token %}
Expand Down
5 changes: 0 additions & 5 deletions volunteers/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@ def check_profile_completeness(request, volunteer):
if request.user != volunteer.user:
return True

if not volunteer.penta_account_name:
messages.warning(request, _(
"Hey there! If you want to be a host for a talk, you must register on Pentabarf at https://penta.fosdem.org/submission/"),
fail_silently=True)

if not volunteer.mobile_nbr:
messages.warning(request, _(
"Hey there! It seems you didn't give us a phone number. Please update your profile, to make sure we can contact you if the network fails..."),
Expand Down

0 comments on commit 7398715

Please sign in to comment.