Merge branch 'develop'

Conflicts:
	2017.pycon-au.org.conf
This commit is contained in:
Nick Seidenman (N6) 2017-02-21 10:57:30 +11:00
commit e4679c7cb8
22 changed files with 401 additions and 45 deletions

1
.gitignore vendored
View file

@ -7,3 +7,4 @@ dev.db
.coverage
pinaxcon/site_media/
local_settings.py
log

View file

@ -5,13 +5,44 @@ WSGIPythonPath /srv/http/2017.pycon-au.org/symposion/website:/srv/http/2017.pyco
ServerName 2017.pycon-au.org
ServerAlias 2017.pycon-au.org
# We need this bit of confignation when we generate site certs at sslforfree.com.
# So please don't get rid of it, and don't uncomment it unless you know wtf you're doing.
#Alias /.well-known/acme-challenge/ /srv/http/2017.pycon-au.org/.well-known/acme-challenge/
#<Directory /srv/http/2017.pycon-au.org/.well-known/acme-challenge>
# Order allow,deny
# Allow from all
#</Directory>
Redirect permanent "/" "https:/uat2017.pycon-au.org/"
ErrorLog /srv/http/2017.pycon-au.org/log/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel debug
CustomLog /srv/http/2017.pycon-au.org/log/access.log combined
ServerSignature On
</VirtualHost>
<VirtualHost 192.55.98.190:443>
ServerAdmin webmaster@pycon-au.org
ServerName uat2017.pycon-au.org
ServerAlias uat2017.pycon-au.org
Alias /favicon.ico /srv/http/2017.pycon-au.org/symposion/website/static/dist/pyconau2017/images/favicon.ico
Alias /robots.txt /srv/http/2017.pycon-au.org/symposion/website/robots.txt
Alias /site_media/static/pyconau2017/ /srv/http/2017.pycon-au.org/symposion/website/static/dist/pyconau2017/
Alias /fonts/ /srv/http/2017.pycon-au.org/symposion/website/static/dist/pyconau2017/css/fonts/
Alias /site_media/static/admin/ /srv/http/2017.pycon-au.org/symposion/lib/python2.7/site-packages/django/contrib/admin/static/admin/
Alias /site_media/static/wagtailadmin/ /srv/http/2017.pycon-au.org/symposion/lib/python2.7/site-packages/wagtail/wagtailadmin/static/wagtailadmin/
Alias /site_media/static/wagtailadmin/ /srv/http/2017.pycon-au.org/symposion/lib/python2.7/site-packages/wagtail/wagtailadmin/static/wagtailadmin/
<Directory /srv/http/2017.pycon-au.org/symposion/website/static/dist/pyconau2017>
Order allow,deny
Allow from all
@ -21,6 +52,14 @@ WSGIPythonPath /srv/http/2017.pycon-au.org/symposion/website:/srv/http/2017.pyco
WSGIDaemonProcess 2017.pycon-au.org python-path="/srv/http/2017.pycon-au.org/symposion/website:/srv/http/2017.pycon-au.org/symposion/lib/python2.7/site-packages:/srv/http/2017.pycon-au.org/symposion/lib/python2.7" home=/srv/http/2017.pycon-au.org/symposion/website user=nicks group=www-data
WSGIProcessGroup 2017.pycon-au.org
Alias /site_media/media/ /srv/http/2017.pycon-au.org/symposion/website/pinaxcon/site_media/media/
<Directory /srv/http/2017.pycon-au.org/symposion/website/pinaxcon/site_media/media/>
Order allow,deny
Allow from all
# Require all granted
</Directory>
<Directory /srv/http/2017.pycon-au.org/symposion/website>
Order allow,deny
Allow from all
@ -29,13 +68,18 @@ WSGIPythonPath /srv/http/2017.pycon-au.org/symposion/website:/srv/http/2017.pyco
WSGIScriptAlias / /srv/http/2017.pycon-au.org/symposion/website/pinaxcon/wsgi.py
ErrorLog /srv/http/2017.pycon-au.org/log/error.log
ErrorLog /srv/http/2017.pycon-au.org/log/ssl-error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel debug
CustomLog /srv/http/2017.pycon-au.org/log/access.log combined
CustomLog /srv/http/2017.pycon-au.org/log/ssl-access.log combined
ServerSignature On
SSLEngine on
SSLCertificateFile /srv/http/uat.2017.pycon-au.org/server.crt
SSLCertificateKeyFile /srv/http/uat.2017.pycon-au.org/server.key
SSLCertificateChainFile /srv/http/uat.2017.pycon-au.org/CAbundle.pem
</VirtualHost>

View file

@ -0,0 +1,24 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.9.7 on 2017-02-17 01:20
from __future__ import unicode_literals
import cms_pages.models
from django.db import migrations
import wagtail.wagtailcore.blocks
import wagtail.wagtailcore.fields
import wagtail.wagtailimages.blocks
class Migration(migrations.Migration):
dependencies = [
('cms_pages', '0019_auto_20170116_1334'),
]
operations = [
migrations.AlterField(
model_name='homepage',
name='body',
field=wagtail.wagtailcore.fields.StreamField([('basic_content', wagtail.wagtailcore.blocks.StructBlock([(b'panel_type', wagtail.wagtailcore.blocks.ChoiceBlock(choices=[('simple', 'Simple panel, no image.'), ('blue_left', 'Left-aligned image, blue-filtered image BG'), ('white_right', 'Right-aligned image, white background')])), (b'heading', wagtail.wagtailcore.blocks.CharBlock(required=True)), (b'inset_illustration', wagtail.wagtailcore.blocks.ChoiceBlock(choices=[('antarctica.svg', 'Antarctica'), ('bridge.svg', 'Bridge'), ('casino.svg', 'Casino'), ('cradle.svg', 'Cradle Mountain'), ('devil.svg', 'Tasmanian Devil'), ('falls.svg', 'Waterfall'), ('hobart.svg', 'Hobart'), ('lavender.svg', 'Lavender'), ('logo-mel.png', 'Pycon AU'), ('Python-logo-notext.svg', 'Python'), ('tuz.svg', 'Tuz'), ('wineglass.svg', 'Wineglass')], required=False)), (b'background_image', wagtail.wagtailimages.blocks.ImageChooserBlock(help_text="This is used as the background image of a blue-left block. It's not used for white-right.", required=False)), (b'body', wagtail.wagtailcore.blocks.RawHTMLBlock(required=True)), (b'link', wagtail.wagtailcore.blocks.StructBlock([(b'page', wagtail.wagtailcore.blocks.PageChooserBlock(help_text='You must specify either this, or the URL.', required=False)), (b'url', wagtail.wagtailcore.blocks.CharBlock(help_text='You must specify either this, or the URL.', required=False)), (b'title', wagtail.wagtailcore.blocks.CharBlock(required=True))])), (b'external_links', wagtail.wagtailcore.blocks.ListBlock(cms_pages.models.ExternalLinksBlock)), (b'compact', wagtail.wagtailcore.blocks.BooleanBlock(help_text="True if this block is to be displayed in 'compact' mode", required=False))])), ('keynotes', wagtail.wagtailcore.blocks.StructBlock([(b'heading', wagtail.wagtailcore.blocks.CharBlock(required=True)), (b'speakers', wagtail.wagtailcore.blocks.ListBlock(cms_pages.models.KeynoteSpeakerBlock))]))]),
),
]

View file

@ -0,0 +1,30 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.9.7 on 2017-02-17 07:57
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('cms_pages', '0020_auto_20170217_1220'),
]
operations = [
migrations.AlterField(
model_name='contentpage',
name='intro',
field=models.CharField(blank=True, max_length=250),
),
migrations.AlterField(
model_name='newsindexpage',
name='intro',
field=models.CharField(blank=True, max_length=250),
),
migrations.AlterField(
model_name='newspage',
name='intro',
field=models.CharField(blank=True, max_length=250),
),
]

View file

@ -122,7 +122,7 @@ class BasicContentBlock(blocks.StructBlock):
heading = blocks.CharBlock(required=True)
inset_illustration = blocks.ChoiceBlock(
choices=ILLUSTRATION_TYPES,
required=True,
required=False,
)
background_image = imageblocks.ImageChooserBlock(
required=False,
@ -217,7 +217,7 @@ class AbstractContentPage(Page):
class Meta:
abstract = True
intro = models.CharField(max_length=250)
intro = models.CharField(max_length=250, blank=True)
body = StreamField([
("rich_text", blocks.RichTextBlock(required=False)),

View file

@ -9,9 +9,17 @@ BASE_DIR = PACKAGE_ROOT
DEBUG = False #bool(int(os.environ.get("DEBUG", "1")))
DATABASES = {
"default": {
"ENGINE": "django.db.backends.sqlite3",
"NAME": os.path.join(PROJECT_ROOT, "dev.db"),
#"default": {
# "ENGINE": "django.db.backends.sqlite3",
# "NAME": os.path.join(PROJECT_ROOT, "dev.db"),
#}
'default': {
'ENGINE': 'django.db.backends.postgresql_psycopg2',
'NAME': 'pycon2017_uat',
'USER': 'pycon2017_uat',
'PASSWORD': 'Eishuqu5johZee3G',
'HOST': '172.16.0.100',
'PORT': '',
}
}
@ -123,6 +131,7 @@ MIDDLEWARE_CLASSES = [
"django.contrib.auth.middleware.AuthenticationMiddleware",
"django.contrib.auth.middleware.SessionAuthenticationMiddleware",
"django.contrib.messages.middleware.MessageMiddleware",
"debug_toolbar.middleware.DebugToolbarMiddleware",
"reversion.middleware.RevisionMiddleware",
"django.middleware.clickjacking.XFrameOptionsMiddleware",
'wagtail.wagtailcore.middleware.SiteMiddleware',
@ -144,6 +153,7 @@ INSTALLED_APPS = [
"django.contrib.sites",
"django.contrib.staticfiles",
"django.contrib.humanize",
"debug_toolbar",
# theme
"bootstrapform",
@ -220,6 +230,29 @@ INSTALLED_APPS = [
"django_nose",
]
DEBUG_TOOLBAR_PANELS = [
'debug_toolbar.panels.versions.VersionsPanel',
'debug_toolbar.panels.timer.TimerPanel',
'debug_toolbar.panels.settings.SettingsPanel',
'debug_toolbar.panels.headers.HeadersPanel',
'debug_toolbar.panels.request.RequestPanel',
'debug_toolbar.panels.sql.SQLPanel',
'debug_toolbar.panels.staticfiles.StaticFilesPanel',
'debug_toolbar.panels.templates.TemplatesPanel',
'debug_toolbar.panels.cache.CachePanel',
'debug_toolbar.panels.signals.SignalsPanel',
'debug_toolbar.panels.logging.LoggingPanel',
'debug_toolbar.panels.redirects.RedirectsPanel',
]
# To use the debug toolbar on a "remote" site (i.e., not on localhost) change
# SHOW_TOOLBAR_CALLBACK's definition, below, to return True, rather than False.
# If you're using this on a local(host) for development, there's no need to
# change it so long as DEBUG (above) is defined as True.
DEBUG_TOOLBAR_CONFIG = {
'INTERCEPT_REDIRECTS': False,
'SHOW_TOOLBAR_CALLBACK': lambda x: False,
}
LOGGING = {
'version': 1,

View file

@ -19,5 +19,22 @@
{% block header_inset_image %}{% endblock %}
{% block content %}
{{ page.body }}
<div class="container">
<div class="row">
<div class="col-md-1">xxx</div>
<div class="col-md-10" >
<div id="announcements" class="jumbotron-white">
<h1>{{ page.title }}</h1>
<p>{{ page.intro }}</p>
<span>{{ page.body }}</span>
</div>
</div>
<div class="col-md-1">
<div id="sponsors" class="wrapper jumbotron-white">
<h4>Sponsors</h4>
{% include "symposion/sponsorship/_vertical_by_level.html" %}
</div>
</div>
</div>
</div>
{% endblock %}

View file

@ -13,6 +13,7 @@
{% block head_title %}{% endblock %}
{% block body %}
THIS IS THE LCA PAGE CONTENT
{% block heading_panel %}
<div class="panel panel__compact panel__bg">

View file

@ -12,25 +12,29 @@
{% block head_title %}{% endblock %}
{% comment %}
{% block body_base %}
{% block body %}
{% block heading_panel %}
<!-- div style="background-image: url('{% block header_background_image %}{% endblock %}');" class="panel--bg"></div -->
{% block topbar_base %}
{% endblock %}
{% endblock %}
{% block content_base %}
<!--div class="l-content-page"-->
{% block content %}
{% endblock %}
<!--/div-->
{% endblock %}
{% endcomment %}
{% block content_base %}
{% block content %}
{% endblock %}
{% endblock %}
{% comment %}
the name "extra_script" doesn't actually match the inherited name...
{% block extra_script %}
<!--script src="{% static 'js/site-92ae8d0d6c.js' %}" type="text/javascript"></script -->
<!-- script src="{% static 'js/site-92ae8d0d6c.js' %}" type="text/javascript"></script -->
{% endblock %}
{% endcomment %}

View file

@ -1,23 +1,18 @@
<!-- site_base.html -->
{% load staticfiles %}
{% load metron_tags %}
{% load i18n %}
{% load sitetree %}
{# <!-- https://gist.github.com/geedmo/5682742--> #}
<!DOCTYPE html>
<html lang="en" class="no-js">
<html lang="en" class="no-js" manifest="{% static 'pyconau2017/manifest.appcache' %}">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="description" content="">
<!-- disable browser cache (for now) -->
<meta http-equiv="cache-control" content="max-age=0" />
<meta http-equiv="cache-control" content="no-cache" />
<meta http-equiv="expires" content="0" />
<meta http-equiv="expires" content="Tue, 01 Jan 1990 12:00:00 GMT" />
{% block viewport %}
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<!-- meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0" -->
{% endblock %}
<title>{% block head_title_base %}{% if SITE_NAME %}{{ SITE_NAME }} | {% endif %}{% block head_title %}{% endblock %}{% endblock %}</title>
@ -26,8 +21,9 @@
<link rel="stylesheet" href="{% static 'pyconau2017/css/app.css' %}">
<link rel="stylesheet" href="{% static 'pyconau2017/css/print.css' %}" media="print">
<link href="{% static 'pyconau2017/css/pyconau.css' %}" rel="stylesheet">
<link href="{% static 'pyconau2017/css/pyconau2016.css' %}" rel="stylesheet">
<link rel="icon" href="{% static 'pyconau2017/images/favicon.png' %}"
<link rel="icon" href="{% static 'pyconau2017/images/favicon.png' %}">
<!--Meta tags-->
<meta name="theme-color" content="#0c486c">
@ -36,8 +32,8 @@
<!--Twitter-->
<meta name="twitter:card" content="summary">
<meta name="twitter:site" content="@pyconau2017">
<meta name="twitter:title" content="Pycon AU 3 - 8 2017 Melbourne, Victoria"
<meta name="twitter:description"content="Discover the future of Open Source at linux.conf.au 2017. Tickets on sale from October.">
<meta name="twitter:title" content="Pycon AU 3 - 8 2017 Melbourne, Victoria">
<meta name="twitter:description" content="Discover the future of Open Source at linux.conf.au 2017. Tickets on sale from October.">
<meta name="twitter:image" content="{{ request.scheme }}://{{ request.get_host }}{% static 'pyconau2017/images/socmed/twitter-tuz.png' %}">
<meta name="twitter:image:alt" content="Tuz">
<!--Open Graph-->
@ -53,36 +49,38 @@
{% endblock %}
</head>
<body class="{% block body_class %}{% endblock %}"
style="background-image: url({% static 'pyconau2017/images/pyconau-2016-collage.jpg' %});">
style="background-image: url({% static 'pyconau2017/images/pyconau-2016-collage-faded.jpg' %});">
{% block topbar_base %}
{% block nav %}
{% comment %}
{% sitetree_menu from "main" include "trunk" template "sitetree_header.html" %}
<a href="#" data-menu-opener="" class="l-header--menu-opener"></a>
{% sitetree_menu from "main" include "trunk" template "sitetree_opener.html" %}
{% endcomment %}
{% endblock %}
{% endblock %}
<!-- site_base block body_base -->
{% block body_base %}
<!--div style="height: 100px;" /-->
<!--main role="main"-->
<!-- site_base block body -->
{% block body %}
{% block content %}
{% endblock %}
{% endblock %}
<!-- site_base endblock body -->
<!--/main-->
<!--/div-->
{% endblock %}
<!-- site_base endblock body_base -->
{% block footer_base %}
<!-- https://gist.github.com/geedmo/5682742-->
<!-- footer class="l-footer l-footer__alt" -->
{% block footer %}
{% endblock %}
</footer>
<!-- /footer -->
{% endblock %}
{% block scripts %}
@ -100,3 +98,4 @@
{% endblock %}
</body>
</html>
<!-- end site_base.html -->

View file

@ -1,18 +1,20 @@
<!-- site_base_wagtail.html -->
{% extends "site_base.html" %}
{% load staticfiles %}
{% block extra_style %}{% endblock %}
{% comment %}
{% block body_base %}
{% comment %}
{% include "_messages.html" %}
{% endcomment %}
<!-- site_base_wagtail.html block body -->
{% block body %}
<!-- begin content -->
{% block content %}
{% endblock %}
<!-- end content -->
{% endblock %}
{% comment %}
<!-- site_base_wagtail.html enblock body -->
{% endblock %}
{% endcomment %}
{% block scripts %}
@ -25,4 +27,5 @@
{% block scripts_extra %}
{% endblock %}
<!-- end site_base_wagtail.html -->
{% endblock %}

View file

@ -1,5 +1,6 @@
{% load sitetree %}
<nav role="navigation" id="LOL" class="l-header--links">
<nav id="LOL" class="l-header--links">
<ul>
{% for item in sitetree_items %}
<li class="l-header--nav">
<a
@ -19,4 +20,5 @@
{% endif %}
</li>
{% endfor %}
</ul>
</nav>

View file

@ -1,11 +1,7 @@
{% load thumbnail %}
{% load pyconau2017_tags %}
{% spaceless %}
<a href="{{ sponsor.external_url }}">
{% if dimensions %}
<img id="sponsor_{{ sponsor.pk }}" src="{% thumbnail sponsor.logo dimensions %}" alt="{{ sponsor.name }}" />
{% else %}
<img id="sponsor_{{ sponsor.pk }}" src="{% thumbnail sponsor.logo '150x150' %}" alt="{{ sponsor.name }}" />
{% endif %}
<img id="sponsor_{{ sponsor.pk }}" src="{% sponsor_thumbnail sponsor.sponsor_logo %}" class="thumbnail" alt="{{ sponsor.name }}" />
</a>
{% endspaceless %}

View file

@ -6,7 +6,7 @@
{% for level in levels %}
<h3>{{ level.name }}</h3>
{% for sponsor in level.sponsors %}
<div>
<div class="sponsor-list">
{% include "symposion/sponsorship/_sponsor_link.html" with sponsor=sponsor %}
</div>
{% endfor %}

View file

@ -2,6 +2,8 @@ import cms_pages
import hashlib
import urllib
import os
from decimal import Decimal
from django import template
from django.conf import settings
@ -101,3 +103,12 @@ def trackname(room, day):
except Track.DoesNotExist:
track_name = None
return track_name
@register.simple_tag()
def sponsor_thumbnail(sponsor_logo):
if sponsor_logo is not None:
if sponsor_logo.upload:
logo_file = os.path.join(settings.MEDIA_URL, str(sponsor_logo.upload))
return logo_file
return ""

View file

@ -13,10 +13,16 @@ from django.contrib import admin
import symposion.views
import debug_toolbar
import sys
urlpatterns = [
url(r"^admin/", include(admin.site.urls)),
# Debug toolbar
url(r"^account/", include("account.urls")),
url(r"^dashboard/", symposion.views.dashboard, name="dashboard"),
@ -49,7 +55,13 @@ urlpatterns = [
#url(r"^$", TemplateView.as_view(template_name="homepage.html"), name="home"),
# Demo payment gateway and related features
# url(r"^register/pinaxcon/", include("pinaxcon.registrasion.urls")),
#url(r"^register/pinaxcon/", include("pinaxcon.registrasion.urls")),
]
if settings.DEBUG:
import debug_toolbar
urlpatterns += [ url(r'^__debug__/', include(debug_toolbar.urls)), ]
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)

View file

@ -12,6 +12,10 @@ pinax-boxes==2.1.2
wagtail==1.6.2
pylibmc==1.5.1
raven==5.27.0
django-debug-toolbar==1.6
# database
psycopg2==2.6.2
#Wiki
wiki==0.1.2

2
robots.txt Normal file
View file

@ -0,0 +1,2 @@
User-agent: *
Disallow: /

View file

@ -0,0 +1,14 @@
CACHE MANIFEST
# 2017-02-17
 Explicitly cached entries ...
CACHE:
/favicon.ico
# Resources that require the user to be on-line
NETWORK:
FALLBACK:

View file

@ -27,6 +27,13 @@ body {
margin-bottom: 60px;
}
.jumbotron-white {
background-color: rgba(255,255,255,1.0);
color: black;
margin-top: 60px;
margin-bottom: 60px;
}
@font-face {
font-family: 'Flux Regular';
src: url('fonts/FLUXRegular.ttf');
@ -38,15 +45,63 @@ body {
}
#announcements {
/*
background-color: rgba(0,0,0,0.9);
color: white;
*/
border-radius: 6px;
padding: 2em;
margin-top: 60px;
margin-bottom: 60px;
}
#announcements h2 {
font-size: 2em;
font-family: 'Flux Regular';
color: white;
/*color: white;*/
}
/* getting nav bar sorted ... (n6) */
nav {
background-color: #000;
width: 100%;
padding-top: 10px;
/*padding-bottom: 10px;*/
padding-left: 20px;
}
.l-header--nav {
font-size: 1.4em;
font-weight: bold;
color: #a6e9f5;
}
.menu-dropdown {
background: #4c4c4b;
}
#sponsors {
border-radius: 6px;
padding: 1em;
margin-top: 60px;
margin-bottom: 60px;
text-align: center;
width: 150px; /* this is a hack. need to figure out exactly where (else) it's being set. */
}
.thumbnail {
width: auto;
height: auto;
max-width: 100px;
max-height: 100px;
border: 0;
}
div.sponsor-list {
min-width: 100px;
display: block;
margin: 0 auto;
}

View file

@ -0,0 +1,104 @@
body {
background: url(/img/mcec_mini.jpg) no-repeat center center fixed;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
}
@font-face {
font-family: 'Flux Regular';
src: url('/fonts/FLUXRegular.ttf');
}
.wrapper {
background-color: rgba(255, 255, 255, 0.9);
border-radius: 6px;
padding: 1em;
}
h1,h2,h3,h4,h5 {
font-family: 'Flux Regular';
}
.font-flux {
font-family: 'Flux Regular';
}
.nav-head {
font-weight: bold;
margin-left: .5em;
}
#t-shirt td {
padding-right: 2em;
}
.prices th {
padding-right: 2em;
}
.prices td {
padding-right: 2em;
}
td {
padding-right: 1em;
}
th {
padding-right: 1em;
}
.mandatory {
color: #ff0000;
background: inherit;
margin-right: 5px;
float: left;
}
ul.entries {
list-style-type: none;
}
.graph-bar-sold
{
background-color: #FF2233;
height: 20px;
float: left;
}
.graph-bar-available
{
background-color: #BBDD99;
height: 20px;
float: left;
}
#programme td, #programme th {
text-align: center;
font-size: 13px;
vertical-align: middle;
border-right: 1px solid #ccc;
}
#programme td {
border-bottom: 1px solid #ccc;
}
#programme td i, #programme th i {
font-style: italic;
}
#programme .programme_break {
background-color: #ececec;
}
#programme .programme_plenary {
background-color: #d7dfe5;
}
#programme .multi {
background-color: #d2e7db;
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 527 KiB