diff --git a/src/utils/management/commands/bootstrap-devsite.py b/src/utils/management/commands/bootstrap-devsite.py index ea297f27..4f669e91 100644 --- a/src/utils/management/commands/bootstrap-devsite.py +++ b/src/utils/management/commands/bootstrap-devsite.py @@ -5,6 +5,8 @@ from camps.models import Camp from news.models import NewsItem from info.models import InfoCategory, InfoItem from villages.models import Village +from feedback.models import Feedback +from rideshare.models import Ride from shop.models import ProductCategory, Product, Order from program.models import ( EventType, @@ -15,195 +17,161 @@ from program.models import ( EventTrack, ) from tickets.models import TicketType -from teams.models import Team, TeamTask, TeamMember +from teams.models import Team, TeamTask, TeamMember, TeamShift from events.models import Type, Routing +from profiles.models import Profile +from sponsors.models import SponsorTier, Sponsor +from tokens.models import Token, TokenFind from django.contrib.auth.models import User from allauth.account.models import EmailAddress from django.utils.text import slugify +from django.utils.crypto import get_random_string +from django.db.models.signals import post_save +import factory +from faker import Faker + +fake = Faker() + + +@factory.django.mute_signals(post_save) +class ProfileFactory(factory.django.DjangoModelFactory): + class Meta: + model = Profile + + user = factory.SubFactory("self.UserFactory", profile=None) + name = factory.Faker("name") + description = factory.Faker("text") + public_credit_name = factory.Faker("name") + public_credit_name_approved = True + + +@factory.django.mute_signals(post_save) +class UserFactory(factory.django.DjangoModelFactory): + class Meta: + model = User + + profile = factory.RelatedFactory(ProfileFactory, "user") + + +class EmailAddressFactory(factory.django.DjangoModelFactory): + class Meta: + model = EmailAddress + + primary = False + verified = True class Command(BaseCommand): args = "none" help = "Create mock data for development instances" - def output(self, message): - self.stdout.write( - "%s: %s" % (timezone.now().strftime("%Y-%m-%d %H:%M:%S"), message) - ) + def output_fake_md_description(self): + fake_text = "\n".join(fake.paragraphs(nb=3, ext_word_list=None)) + fake_text += "\n\n" + fake_text += "\n".join(fake.paragraphs(nb=3, ext_word_list=None)) + fake_text += "\n\n" + fake_text += "## " + fake.sentence(nb_words=3) + "\n" + fake_text += "\n".join(fake.paragraphs(nb=3, ext_word_list=None)) + fake_text += "\n\n" + fake_text += '![The image is not awailable](/static/img/na.jpg "not awailable")' + fake_text += "\n\n" + fake_text += "\n".join(fake.paragraphs(nb=3, ext_word_list=None)) + fake_text += "\n\n" + fake_text += "* [" + fake.sentence(nb_words=3) + "](" + fake.uri() + ")\n" + fake_text += "* [" + fake.sentence(nb_words=3) + "](" + fake.uri() + ")\n" - def handle(self, *args, **options): + return fake_text + + def output_fake_description(self): + fake_text = "\n".join(fake.paragraphs(nb=3, ext_word_list=None)) + fake_text += "* [" + fake.sentence(nb_words=3) + "](" + fake.uri() + ")\n" + + return fake_text + + def create_camps(self): self.output("Creating camps...") - camp2016 = Camp.objects.create( - title="BornHack 2016", - tagline="Initial Commit", - slug="bornhack-2016", - shortslug="bh2016", - buildup=( - timezone.datetime(2016, 8, 25, 12, 0, tzinfo=timezone.utc), - timezone.datetime(2016, 8, 27, 11, 59, tzinfo=timezone.utc), - ), - camp=( - timezone.datetime(2016, 8, 27, 12, 0, tzinfo=timezone.utc), - timezone.datetime(2016, 9, 4, 11, 59, tzinfo=timezone.utc), - ), - teardown=( - timezone.datetime(2016, 9, 4, 12, 0, tzinfo=timezone.utc), - timezone.datetime(2016, 9, 6, 12, 0, tzinfo=timezone.utc), - ), - colour="#004dff", - ) + camps = [ + dict(year=2016, tagline="Initial Commit", colour="#004dff", read_only=True), + dict(year=2017, tagline="Make Tradition", colour="#750787", read_only=True), + dict(year=2018, tagline="scale it", colour="#008026", read_only=True), + dict(year=2019, tagline="a new /home", colour="#ffed00", read_only=False), + dict(year=2020, tagline="Undecided", colour="#ff8c00", read_only=False), + dict(year=2021, tagline="Undecided", colour="#e40303", read_only=False), + ] - camp2017 = Camp.objects.create( - title="BornHack 2017", - tagline="Make Tradition", - slug="bornhack-2017", - shortslug="bh2017", - buildup=( - timezone.datetime(2017, 8, 25, 12, 0, tzinfo=timezone.utc), - timezone.datetime(2017, 8, 27, 11, 59, tzinfo=timezone.utc), - ), - camp=( - timezone.datetime(2017, 8, 27, 12, 0, tzinfo=timezone.utc), - timezone.datetime(2017, 9, 4, 11, 59, tzinfo=timezone.utc), - ), - teardown=( - timezone.datetime(2017, 9, 4, 12, 0, tzinfo=timezone.utc), - timezone.datetime(2017, 9, 6, 12, 0, tzinfo=timezone.utc), - ), - colour="#750787", - ) + camp_instances = [] - camp2018 = Camp.objects.create( - title="BornHack 2018", - tagline="scale it", - slug="bornhack-2018", - shortslug="bh2018", - call_for_participation_open=True, - call_for_sponsors_open=True, - buildup=( - timezone.datetime(2018, 8, 25, 12, 0, tzinfo=timezone.utc), - timezone.datetime(2018, 8, 27, 11, 59, tzinfo=timezone.utc), - ), - camp=( - timezone.datetime(2018, 8, 27, 12, 0, tzinfo=timezone.utc), - timezone.datetime(2018, 9, 4, 11, 59, tzinfo=timezone.utc), - ), - teardown=( - timezone.datetime(2018, 9, 4, 12, 0, tzinfo=timezone.utc), - timezone.datetime(2018, 9, 6, 12, 0, tzinfo=timezone.utc), - ), - colour="#008026", - ) + for camp in camps: + year = camp["year"] + read_only = camp["read_only"] + camp_instances.append( + ( + Camp.objects.create( + title="BornHack {}".format(year), + tagline=camp["tagline"], + slug="bornhack-{}".format(year), + shortslug="bornhack-{}".format(year), + buildup=( + timezone.datetime(year, 8, 25, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 27, 12, 0, tzinfo=timezone.utc), + ), + camp=( + timezone.datetime(year, 8, 27, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 4, 11, 0, tzinfo=timezone.utc), + ), + teardown=( + timezone.datetime(year, 9, 4, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 6, 12, 0, tzinfo=timezone.utc), + ), + colour=camp["colour"], + ), + read_only, + ) + ) + return camp_instances + + def create_users(self): self.output("Creating users...") - user1 = User.objects.create_user(username="user1", password="user1") - user1.profile.name = "John Doe" - user1.profile.description = "one that once was" - user1.profile.public_credit_name = "PublicDoe" - user1.profile.public_credit_name_approved = True - user1.profile.save() - email = EmailAddress.objects.create( - user=user1, email="user1@example.com", primary=False, verified=True - ) - email.set_as_primary() - user2 = User.objects.create_user(username="user2", password="user2") - user2.profile.name = "Jane Doe" - user2.profile.description = "one that once was" - user2.profile.save() - email = EmailAddress.objects.create( - user=user2, email="user2@example.com", primary=False, verified=True - ) - email.set_as_primary() + users = {} - user3 = User.objects.create_user(username="user3", password="user3") - user3.profile.name = "Lorem Ipsum" - user3.profile.description = "just a user" - user3.profile.public_credit_name = "Lorem Ipsum" - user3.profile.save() - email = EmailAddress.objects.create( - user=user3, email="user3@example.com", primary=False, verified=True - ) - email.set_as_primary() - - user4 = User.objects.create_user(username="user4", password="user4") - user4.profile.name = "Ethe Reum" - user4.profile.description = "I prefer doge" - user4.profile.public_credit_name = "Dogefan" - user4.profile.public_credit_name_approved = True - user4.profile.save() - email = EmailAddress.objects.create( - user=user4, email="user4@example.com", primary=False, verified=True - ) - email.set_as_primary() - - user5 = User.objects.create_user(username="user5", password="user5") - user5.profile.name = "Pyra Mid" - user5.profile.description = "This is not a scam" - user5.profile.public_credit_name = "Ponziarne" - user5.profile.public_credit_name_approved = True - user5.profile.save() - email = EmailAddress.objects.create( - user=user5, email="user5@example.com", primary=False, verified=True - ) - email.set_as_primary() - - user6 = User.objects.create_user(username="user6", password="user6") - user6.profile.name = "User Number 6" - user6.profile.description = "some description" - user6.profile.public_credit_name = "bruger 6" - user6.profile.public_credit_name_approved = True - user6.profile.save() - email = EmailAddress.objects.create( - user=user6, email="user6@example.com", primary=False, verified=True - ) - email.set_as_primary() - - user7 = User.objects.create_user(username="user7", password="user7") - user7.profile.name = "Assembly Hacker" - user7.profile.description = "Low level is best level" - user7.profile.public_credit_name = "asm" - user7.profile.public_credit_name_approved = True - user7.profile.save() - email = EmailAddress.objects.create( - user=user7, email="user7@example.com", primary=False, verified=True - ) - email.set_as_primary() - - user8 = User.objects.create_user(username="user8", password="user8") - user8.profile.name = "TCL" - user8.profile.description = "Expect me" - user8.profile.public_credit_name = "TCL lover" - user8.profile.public_credit_name_approved = True - user8.profile.save() - email = EmailAddress.objects.create( - user=user8, email="user8@example.com", primary=False, verified=True - ) - email.set_as_primary() - - user9 = User.objects.create_user(username="user9", password="user9") - user9.profile.name = "John Windows" - user9.profile.description = "Microsoft is best soft" - user9.profile.public_credit_name = "msboy" - user9.profile.save() - email = EmailAddress.objects.create( - user=user9, email="user9@example.com", primary=False, verified=True - ) - email.set_as_primary() + for i in range(1, 10): + username = "user{}".format(i) + user = UserFactory.create( + username=username, email="{}@example.com".format(username) + ) + user.set_password(username) + user.save() + users[i] = user + EmailAddressFactory.create( + user=user, email="{}@example.com".format(username) + ) admin = User.objects.create_superuser( username="admin", email="admin@example.com", password="admin" ) - admin.profile.name = "Ad min" - admin.profile.description = "I can administer the admin rights" + users["admin"] = admin + admin.profile.name = "Administrator" + admin.profile.description = "Default adminstrative user" + admin.profile.public_credit_name = "Administrator" + admin.profile.public_credit_name_approved = True admin.profile.save() - email = EmailAddress.objects.create( - user=admin, email="admin@example.com", verified=True + EmailAddress.objects.create( + user=admin, email="admin@example.com", verified=True, primary=True ) - email.set_as_primary() + return users + + def create_news(self): + NewsItem.objects.create( + title="unpublished news item", content="unpublished news body here" + ) + + def create_event_types(self): + types = {} self.output("Creating event types...") - workshop = EventType.objects.create( + types["workshop"] = EventType.objects.create( name="Workshop", slug="workshop", color="#ff9900", @@ -214,7 +182,7 @@ class Command(BaseCommand): host_title="Host", ) - talk = EventType.objects.create( + types["talk"] = EventType.objects.create( name="Talk", slug="talk", color="#2D9595", @@ -225,7 +193,7 @@ class Command(BaseCommand): host_title="Speaker", ) - lightning = EventType.objects.create( + types["lightning"] = EventType.objects.create( name="Lightning Talk", slug="lightning-talk", color="#ff0000", @@ -236,7 +204,7 @@ class Command(BaseCommand): host_title="Speaker", ) - music = EventType.objects.create( + types["music"] = EventType.objects.create( name="Music Act", slug="music", color="#1D0095", @@ -247,7 +215,7 @@ class Command(BaseCommand): host_title="Artist", ) - keynote = EventType.objects.create( + types["keynote"] = EventType.objects.create( name="Keynote", slug="keynote", color="#FF3453", @@ -257,7 +225,7 @@ class Command(BaseCommand): host_title="Speaker", ) - debate = EventType.objects.create( + types["debate"] = EventType.objects.create( name="Debate", slug="debate", color="#F734C3", @@ -268,7 +236,7 @@ class Command(BaseCommand): public=True, ) - facility = EventType.objects.create( + types["facility"] = EventType.objects.create( name="Facilities", slug="facilities", color="#cccccc", @@ -279,7 +247,7 @@ class Command(BaseCommand): host_title="Host", ) - slack = EventType.objects.create( + types["slack"] = EventType.objects.create( name="Recreational Event", slug="recreational-event", color="#0000ff", @@ -290,25 +258,33 @@ class Command(BaseCommand): host_title="Host", ) + return types + + def create_product_categories(self): + categories = {} self.output("Creating productcategories...") - transportation = ProductCategory.objects.create( + categories["transportation"] = ProductCategory.objects.create( name="Transportation", slug="transportation" ) - merchandise = ProductCategory.objects.create( + categories["merchandise"] = ProductCategory.objects.create( name="Merchandise", slug="merchandise" ) - tickets = ProductCategory.objects.create(name="Tickets", slug="tickets") - villages = ProductCategory.objects.create(name="Villages", slug="villages") - - NewsItem.objects.create( - title="unpublished news item", content="unpublished news body here" + categories["tickets"] = ProductCategory.objects.create( + name="Tickets", slug="tickets" + ) + categories["villages"] = ProductCategory.objects.create( + name="Villages", slug="villages" ) - self.output("Creating products...") + return categories + + def create_global_products(self, categories): + products = {} + self.output("Creating global products...") name = "PROSA bus transport (PROSA members only)" - product0 = Product.objects.create( + products["product0"] = Product.objects.create( name=name, - category=transportation, + category=categories["transportation"], price=125, description="PROSA is sponsoring a bustrip from Copenhagen to the venue and back.", available_in=( @@ -319,9 +295,9 @@ class Command(BaseCommand): ) name = "PROSA bus transport (open for everyone)" - product1 = Product.objects.create( + products["product1"] = Product.objects.create( name=name, - category=transportation, + category=categories["transportation"], price=125, description="PROSA is sponsoring a bustrip from Copenhagen to the venue and back.", available_in=( @@ -332,9 +308,9 @@ class Command(BaseCommand): ) name = "T-shirt (large)" - product2 = Product.objects.create( + products["product2"] = Product.objects.create( name=name, - category=merchandise, + category=categories["merchandise"], price=160, description="Get a nice t-shirt", available_in=( @@ -345,11 +321,11 @@ class Command(BaseCommand): ) name = "Village tent 3x3 meters, no floor" - tent1 = Product.objects.create( + products["tent1"] = Product.objects.create( name=name, description="A description of the tent goes here", price=3325, - category=villages, + category=categories["villages"], available_in=( timezone.datetime(2017, 3, 1, 12, 0, tzinfo=timezone.utc), timezone.datetime(2017, 8, 20, 12, 0, tzinfo=timezone.utc), @@ -358,11 +334,11 @@ class Command(BaseCommand): ) name = "Village tent 3x3 meters, with floor" - tent2 = Product.objects.create( + products["tent2"] = Product.objects.create( name=name, description="A description of the tent goes here", price=3675, - category=villages, + category=categories["villages"], available_in=( timezone.datetime(2017, 3, 1, 12, 0, tzinfo=timezone.utc), timezone.datetime(2017, 8, 20, 12, 0, tzinfo=timezone.utc), @@ -370,1136 +346,1316 @@ class Command(BaseCommand): slug="{}".format(slugify(name)), ) - for camp in [camp2016, camp2017, camp2018]: + return products + + def create_camp_ticket_types(self, camp): + types = {} + self.output("Creating tickettypes for {}...".format(camp.camp.lower.year)) + types["adult_full_week"] = TicketType.objects.create( + name="Adult Full Week", camp=camp + ) + types["adult_one_day"] = TicketType.objects.create( + name="Adult One Day", camp=camp + ) + types["child_full_week"] = TicketType.objects.create( + name="Child Full Week", camp=camp + ) + types["child_one_day"] = TicketType.objects.create( + name="Child One Day", camp=camp + ) + + return types + + def create_camp_products(self, camp, categories, ticket_types): + products = {} + year = camp.camp.lower.year + name = "BornHack {} Standard ticket".format(year) + products["ticket1"] = Product.objects.create( + name=name, + description="A ticket", + price=1200, + category=categories["tickets"], + available_in=( + timezone.datetime(year, 1, 1, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 12, 20, 12, 0, tzinfo=timezone.utc), + ), + slug="{}".format(slugify(name)), + ticket_type=ticket_types["adult_full_week"], + ) + + name = "BornHack {} Hacker ticket".format(year) + products["ticket2"] = Product.objects.create( + name=name, + description="Another ticket", + price=1337, + category=categories["tickets"], + available_in=( + timezone.datetime(year, 1, 1, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 12, 20, 12, 0, tzinfo=timezone.utc), + ), + slug="{}".format(slugify(name)), + ticket_type=ticket_types["adult_full_week"], + ) + + return products + + def create_orders(self, users, global_products, camp_products): + orders = {} + self.output("Creating orders...") + orders[0] = Order.objects.create( + user=users[1], payment_method="cash", open=None, paid=True + ) + orders[0].orderproductrelation_set.create( + product=camp_products["ticket1"], quantity=1 + ) + orders[0].orderproductrelation_set.create( + product=global_products["tent1"], quantity=1 + ) + orders[0].mark_as_paid(request=None) + + orders[1] = Order.objects.create( + user=users[2], payment_method="cash", open=None + ) + orders[1].orderproductrelation_set.create( + product=camp_products["ticket1"], quantity=1 + ) + orders[1].orderproductrelation_set.create( + product=global_products["tent2"], quantity=1 + ) + orders[1].mark_as_paid(request=None) + + orders[2] = Order.objects.create( + user=users[3], payment_method="cash", open=None + ) + orders[2].orderproductrelation_set.create( + product=camp_products["ticket2"], quantity=1 + ) + orders[2].orderproductrelation_set.create( + product=camp_products["ticket1"], quantity=1 + ) + orders[2].orderproductrelation_set.create( + product=global_products["tent2"], quantity=1 + ) + orders[2].mark_as_paid(request=None) + + orders[3] = Order.objects.create( + user=users[4], payment_method="cash", open=None + ) + orders[3].orderproductrelation_set.create( + product=global_products["product0"], quantity=1 + ) + orders[3].orderproductrelation_set.create( + product=camp_products["ticket2"], quantity=1 + ) + orders[3].orderproductrelation_set.create( + product=global_products["tent1"], quantity=1 + ) + orders[3].mark_as_paid(request=None) + + return orders + + def create_camp_tracks(self, camp): + tracks = {} + year = camp.camp.lower.year + self.output("Creating eventtracks for {}...".format(year)) + tracks[1] = EventTrack.objects.create( + camp=camp, name="BornHack", slug=camp.slug + ) + + return tracks + + def create_camp_locations(self, camp): + locations = {} + year = camp.camp.lower.year + self.output("Creating eventlocations for {}...".format(year)) + locations["speakers_tent"] = EventLocation.objects.create( + name="Speakers Tent", slug="speakers-tent", icon="comment", camp=camp + ) + locations["workshop_room"] = EventLocation.objects.create( + name="Workshop rooms", slug="workshop-rooms", icon="briefcase", camp=camp + ) + locations["bar_area"] = EventLocation.objects.create( + name="Bar Area", slug="bar-area", icon="glass", camp=camp + ) + locations["food_area"] = EventLocation.objects.create( + name="Food Area", slug="food-area", icon="cutlery", camp=camp + ) + + return locations + + def create_camp_news(self, camp): + year = camp.camp.lower.year + self.output("Creating news for {}...".format(year)) + NewsItem.objects.create( + title="Welcome to {}".format(camp.title), + content="news body here with html support", + published_at=timezone.datetime(year, 8, 27, 12, 0, tzinfo=timezone.utc), + ) + NewsItem.objects.create( + title="{} is over".format(camp.title), + content="news body here", + published_at=timezone.datetime(year, 9, 4, 12, 0, tzinfo=timezone.utc), + ) + + def create_camp_events(self, camp, tracks, event_types): + events = {} + year = camp.camp.lower.year + self.output("Creating events for {}...".format(year)) + events[1] = Event.objects.create( + title="Developing the BornHack website", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[2] = Event.objects.create( + title="State of the world", + abstract=self.output_fake_md_description(), + event_type=event_types["keynote"], + track=tracks[1], + ) + events[3] = Event.objects.create( + title="Welcome to bornhack!", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[4] = Event.objects.create( + title="bar is open", + abstract=self.output_fake_md_description(), + event_type=event_types["facility"], + track=tracks[1], + ) + events[5] = Event.objects.create( + title="Network something", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[6] = Event.objects.create( + title="State of outer space", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[9] = Event.objects.create( + title="The Alternative Welcoming", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[10] = Event.objects.create( + title="Words and Power - are we making the most of online activism?", + abstract=self.output_fake_md_description(), + event_type=event_types["keynote"], + track=tracks[1], + ) + events[11] = Event.objects.create( + title="r4d1o hacking 101", + abstract=self.output_fake_md_description(), + event_type=event_types["workshop"], + track=tracks[1], + ) + events[12] = Event.objects.create( + title="Introduction to Sustainable Growth in a Digital World", + abstract=self.output_fake_md_description(), + event_type=event_types["workshop"], + track=tracks[1], + ) + events[13] = Event.objects.create( + title="American Fuzzy Lop and Address Sanitizer", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[14] = Event.objects.create( + title="PGP Keysigning Party", + abstract=self.output_fake_md_description(), + event_type=event_types["workshop"], + track=tracks[1], + ) + events[15] = Event.objects.create( + title="Bluetooth Low Energy", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[16] = Event.objects.create( + title="TLS attacks and the burden of faulty TLS implementations", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[17] = Event.objects.create( + title="State of the Network", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[18] = Event.objects.create( + title="Running Exit Nodes in the North", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[19] = Event.objects.create( + title="Hacker Jeopardy Qualifier", + abstract=self.output_fake_description(), + event_type=event_types["slack"], + track=tracks[1], + ) + events[20] = Event.objects.create( + title="Hacker Jeopardy Finals", + abstract=self.output_fake_description(), + event_type=event_types["slack"], + track=tracks[1], + ) + events[21] = Event.objects.create( + title="Incompleteness Phenomena in Mathematics: From Kurt Gödel to Harvey Friedman", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[22] = Event.objects.create( + title="Infocalypse Now - and how to Survive It?", + abstract=self.output_fake_md_description(), + event_type=event_types["keynote"], + track=tracks[1], + ) + events[23] = Event.objects.create( + title="Liquid Democracy (Introduction and Debate)", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[24] = Event.objects.create( + title="Badge Workshop", + abstract=self.output_fake_md_description(), + event_type=event_types["workshop"], + track=tracks[1], + ) + events[25] = Event.objects.create( + title="Checking a Distributed Hash Table for Correctness", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[26] = Event.objects.create( + title="GraphQL - A Data Language", + abstract=self.output_fake_md_description(), + event_type=event_types["talk"], + track=tracks[1], + ) + events[27] = Event.objects.create( + title="Visualisation of Public Datasets", + abstract=self.output_fake_md_description(), + event_type=event_types["workshop"], + track=tracks[1], + ) + events[28] = Event.objects.create( + title="Local delicacies", + abstract=self.output_fake_md_description(), + event_type=event_types["facility"], + track=tracks[1], + ) + events[29] = Event.objects.create( + title="Local delicacies from the world", + abstract=self.output_fake_md_description(), + event_type=event_types["facility"], + track=tracks[1], + ) + + return events + + def create_camp_speakers(self, camp, events): + speakers = {} + year = camp.camp.lower.year + self.output("Creating speakers for {}...".format(year)) + speakers[1] = Speaker.objects.create( + name="Henrik Kramse", + biography=self.output_fake_description(), + slug="henrik-kramshj", + camp=camp, + email="email@example.com", + ) + speakers[1].events.add(events[5]) + speakers[2] = Speaker.objects.create( + name="Thomas Tykling", + biography=self.output_fake_description(), + slug="thomas-tykling", + camp=camp, + email="email@example.com", + ) + speakers[2].events.add(events[3], events[1]) + speakers[3] = Speaker.objects.create( + name="Alex Ahf", + biography=self.output_fake_description(), + slug="alex-ahf", + camp=camp, + email="email@example.com", + ) + speakers[3].events.add(events[4], events[2]) + speakers[4] = Speaker.objects.create( + name="Jesper Arp", + biography=self.output_fake_description(), + slug="jesper-arp", + camp=camp, + email="email@example.com", + ) + speakers[4].events.add(events[9], events[27]) + speakers[5] = Speaker.objects.create( + name="Rolf Bjerre", + biography=self.output_fake_description(), + slug="rolf-bjerre", + camp=camp, + email="email@example.com", + ) + speakers[5].events.add(events[9], events[23]) + speakers[6] = Speaker.objects.create( + name="Emma Holten", + biography=self.output_fake_description(), + slug="emma-holten", + camp=camp, + email="email@example.com", + ) + speakers[6].events.add(events[10]) + speakers[7] = Speaker.objects.create( + name="Christoffer Jerkeby", + biography=self.output_fake_description(), + slug="christoffer-jerkeby", + camp=camp, + email="email@example.com", + ) + speakers[7].events.add(events[11]) + speakers[8] = Speaker.objects.create( + name="Stephan Engberg", + biography=self.output_fake_description(), + slug="stephan-engberg", + camp=camp, + email="email@example.com", + ) + speakers[8].events.add(events[12]) + speakers[9] = Speaker.objects.create( + name="Hanno Böck", + biography=self.output_fake_description(), + slug="hanno-bock", + camp=camp, + email="email@example.com", + ) + speakers[9].events.add(events[13], events[16]) + speakers[10] = Speaker.objects.create( + name="Ximin Luo", + biography=self.output_fake_description(), + slug="ximin-luo", + camp=camp, + email="email@example.com", + ) + speakers[10].events.add(events[14]) + speakers[11] = Speaker.objects.create( + name="Michael Knudsen", + biography=self.output_fake_description(), + slug="michael-knudsen", + camp=camp, + email="email@example.com", + ) + speakers[11].events.add(events[15]) + speakers[12] = Speaker.objects.create( + name="BornHack Network Team", + biography=self.output_fake_description(), + slug="bornhack-network-team", + camp=camp, + email="email@example.com", + ) + speakers[12].events.add(events[17]) + speakers[13] = Speaker.objects.create( + name="Juha Nurmi", + biography=self.output_fake_description(), + slug="juha-nurmi", + camp=camp, + email="email@example.com", + ) + speakers[13].events.add(events[18]) + speakers[14] = Speaker.objects.create( + name="Lasse Andersen", + biography=self.output_fake_description(), + slug="lasse-andersen", + camp=camp, + email="email@example.com", + ) + speakers[14].events.add(events[21]) + speakers[15] = Speaker.objects.create( + name="Anders Kjærulff", + biography=self.output_fake_description(), + slug="anders-kjrulff", + camp=camp, + email="email@example.com", + ) + speakers[15].events.add(events[22]) + speakers[16] = Speaker.objects.create( + name="Thomas Flummer", + biography=self.output_fake_description(), + slug="thomas-flummer", + camp=camp, + email="email@example.com", + ) + speakers[16].events.add(events[24]) + speakers[17] = Speaker.objects.create( + name="Jesper Louis Andersen", + biography=self.output_fake_description(), + slug="jesper-louis-andersen", + camp=camp, + email="email@example.com", + ) + speakers[17].events.add(events[25], events[26]) + + return speakers + + def create_camp_scheduling(self, camp, events, locations): + year = camp.camp.lower.year + self.output("Creating eventinstances for {}...".format(year)) + EventInstance.objects.create( + event=events[3], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 27, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 27, 13, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[1], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 28, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 28, 13, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[2], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 29, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 29, 13, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[4], + location=locations["bar_area"], + when=( + timezone.datetime(year, 8, 27, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 28, 5, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[4], + location=locations["bar_area"], + when=( + timezone.datetime(year, 8, 28, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 29, 5, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[4], + location=locations["bar_area"], + when=( + timezone.datetime(year, 8, 29, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 30, 5, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[4], + location=locations["bar_area"], + when=( + timezone.datetime(year, 8, 30, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 31, 5, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[4], + location=locations["bar_area"], + when=( + timezone.datetime(year, 8, 31, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 1, 5, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[4], + location=locations["bar_area"], + when=( + timezone.datetime(year, 9, 1, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 2, 5, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[4], + location=locations["bar_area"], + when=( + timezone.datetime(year, 9, 2, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 3, 5, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[5], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 28, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 28, 13, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[6], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 29, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 29, 13, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[9], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 30, 11, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 30, 11, 30, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[10], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 30, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 30, 13, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[12], + location=locations["workshop_room"], + when=( + timezone.datetime(year, 8, 30, 9, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 30, 11, 30, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[11], + location=locations["workshop_room"], + when=( + timezone.datetime(year, 8, 31, 14, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 31, 16, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[18], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 9, 2, 14, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 2, 15, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[18], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 9, 2, 16, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 2, 17, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[15], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 9, 1, 15, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 1, 16, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[14], + location=locations["workshop_room"], + when=( + timezone.datetime(year, 8, 31, 21, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 31, 22, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[16], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 9, 1, 14, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 1, 15, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[13], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 31, 17, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 31, 18, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[19], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 30, 22, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 30, 23, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[19], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 29, 22, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 29, 23, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[19], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 28, 22, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 28, 23, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[19], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 31, 22, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 31, 23, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[19], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 9, 1, 22, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 1, 23, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[20], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 9, 2, 20, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 2, 22, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[21], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 28, 12, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 28, 13, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[22], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 28, 18, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 28, 19, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[23], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 29, 9, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 29, 11, 30, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[24], + location=locations["workshop_room"], + when=( + timezone.datetime(year, 8, 29, 20, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 29, 22, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[25], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 9, 1, 17, 0, tzinfo=timezone.utc), + timezone.datetime(year, 9, 1, 18, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[26], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 8, 30, 11, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 30, 12, 0, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[26], + location=locations["speakers_tent"], + when=( + timezone.datetime(year, 9, 1, 11, 45, tzinfo=timezone.utc), + timezone.datetime(year, 9, 1, 12, 30, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[28], + location=locations["food_area"], + when=( + timezone.datetime(year, 9, 1, 18, 30, tzinfo=timezone.utc), + timezone.datetime(year, 9, 1, 21, 30, tzinfo=timezone.utc), + ), + ) + EventInstance.objects.create( + event=events[29], + location=locations["food_area"], + when=( + timezone.datetime(year, 8, 29, 18, 30, tzinfo=timezone.utc), + timezone.datetime(year, 8, 29, 23, 30, tzinfo=timezone.utc), + ), + ) + + def create_camp_villages(self, camp, users): + year = camp.camp.lower.year + self.output("Creating villages for {}...".format(year)) + Village.objects.create( + contact=users[1], + camp=camp, + name="Baconsvin", + slug="baconsvin", + description="The camp with the doorbell-pig! Baconsvin is a group of happy people from Denmark doing a lot of open source, and are always happy to talk about infosec, hacking, BSD, and much more. A lot of the organizers of BornHack live in Baconsvin village. Come by and squeeze the pig and sign our guestbook!", + ) + Village.objects.create( + contact=users[2], + camp=camp, + name="NetworkWarriors", + slug="networkwarriors", + description="We will have a tent which house the NOC people, various lab equipment people can play with, and have fun. If you want to talk about networking, come by, and if you have trouble with the Bornhack network contact us.", + ) + Village.objects.create( + contact=users[3], + camp=camp, + name="TheCamp.dk", + slug="the-camp", + description="This village is representing TheCamp.dk, an annual danish tech camp held in July. The official subjects for this event is open source software, network and security. In reality we are interested in anything from computers to illumination soap bubbles and irish coffee", + ) + + def create_camp_teams(self, camp): + teams = {} + year = camp.camp.lower.year + self.output("Creating teams for {}...".format(year)) + teams["orga"] = Team.objects.create( + name="Orga", + description="The Orga team are the main organisers. All tasks are Orga responsibility until they are delegated to another team", + camp=camp, + needs_members=False, + ) + teams["noc"] = Team.objects.create( + name="NOC", + description="The NOC team is in charge of establishing and running a network onsite.", + camp=camp, + ) + teams["bar"] = Team.objects.create( + name="Bar", + description="The Bar team plans, builds and run the IRL bar!", + camp=camp, + ) + teams["shuttle"] = Team.objects.create( + name="Shuttle", + description="The shuttle team drives people to and from the trainstation or the supermarket", + camp=camp, + ) + + return teams + + def create_camp_team_tasks(self, camp, teams): + year = camp.camp.lower.year + self.output("Creating TeamTasks for {}...".format(year)) + TeamTask.objects.create( + team=teams["noc"], + name="Setup private networks", + description="All the private networks need to be setup", + ) + TeamTask.objects.create( + team=teams["noc"], + name="Setup public networks", + description="All the public networks need to be setup", + ) + TeamTask.objects.create( + team=teams["noc"], + name="Deploy access points", + description="All access points need to be deployed", + ) + TeamTask.objects.create( + team=teams["noc"], + name="Deploy fiber cables", + description="We need the fiber deployed where necessary", + ) + TeamTask.objects.create( + team=teams["bar"], + name="List of booze", + description="A list of the different booze we need to have in the bar durng bornhack", + ) + TeamTask.objects.create( + team=teams["bar"], + name="Chairs", + description="We need a solution for chairs", + ) + TeamTask.objects.create( + team=teams["bar"], name="Taps", description="Taps must be ordered" + ) + TeamTask.objects.create( + team=teams["bar"], + name="Coffee", + description="We need to get some coffee for our coffee machine", + ) + TeamTask.objects.create( + team=teams["bar"], + name="Ice", + description="We need ice cubes and crushed ice in the bar", + ) + + def create_camp_team_memberships(self, camp, teams, users): + memberships = {} + year = camp.camp.lower.year + self.output("Creating team memberships for {}...".format(year)) + # noc team + memberships["noc"] = {} + memberships["noc"]["user4"] = TeamMember.objects.create( + team=teams["noc"], user=users[4], approved=True, responsible=True + ) + memberships["noc"]["user1"] = TeamMember.objects.create( + team=teams["noc"], user=users[1], approved=True + ) + memberships["noc"]["user5"] = TeamMember.objects.create( + team=teams["noc"], user=users[5], approved=True + ) + memberships["noc"]["user2"] = TeamMember.objects.create( + team=teams["noc"], user=users[2] + ) + + # bar team + memberships["bar"] = {} + memberships["bar"]["user1"] = TeamMember.objects.create( + team=teams["bar"], user=users[1], approved=True, responsible=True + ) + memberships["bar"]["user3"] = TeamMember.objects.create( + team=teams["bar"], user=users[3], approved=True, responsible=True + ) + memberships["bar"]["user2"] = TeamMember.objects.create( + team=teams["bar"], user=users[2], approved=True + ) + memberships["bar"]["user7"] = TeamMember.objects.create( + team=teams["bar"], user=users[7], approved=True + ) + memberships["bar"]["user8"] = TeamMember.objects.create( + team=teams["bar"], user=users[8] + ) + + # orga team + memberships["orga"] = {} + memberships["orga"]["user1"] = TeamMember.objects.create( + team=teams["orga"], user=users[1], approved=True, responsible=True + ) + memberships["orga"]["user3"] = TeamMember.objects.create( + team=teams["orga"], user=users[3], approved=True, responsible=True + ) + memberships["orga"]["user8"] = TeamMember.objects.create( + team=teams["orga"], user=users[8], approved=True, responsible=True + ) + memberships["orga"]["user9"] = TeamMember.objects.create( + team=teams["orga"], user=users[9], approved=True, responsible=True + ) + memberships["orga"]["user4"] = TeamMember.objects.create( + team=teams["orga"], user=users[4], approved=True, responsible=True + ) + + # shuttle team + memberships["shuttle"] = {} + memberships["shuttle"]["user7"] = TeamMember.objects.create( + team=teams["shuttle"], user=users[7], approved=True, responsible=True + ) + memberships["shuttle"]["user3"] = TeamMember.objects.create( + team=teams["shuttle"], user=users[3], approved=True + ) + memberships["shuttle"]["user9"] = TeamMember.objects.create( + team=teams["shuttle"], user=users[9] + ) + + return memberships + + def create_camp_team_shifts(self, camp, teams, team_memberships): + shifts = {} + year = camp.camp.lower.year + self.output("Creating team shifts for {}...".format(year)) + shifts[0] = TeamShift.objects.create( + team=teams["shuttle"], + shift_range=( + timezone.datetime(year, 8, 27, 2, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 27, 8, 0, tzinfo=timezone.utc), + ), + people_required=1, + ) + shifts[0].team_members.add(team_memberships["shuttle"]["user7"]) + shifts[1] = TeamShift.objects.create( + team=teams["shuttle"], + shift_range=( + timezone.datetime(year, 8, 27, 8, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 27, 14, 0, tzinfo=timezone.utc), + ), + people_required=1, + ) + shifts[2] = TeamShift.objects.create( + team=teams["shuttle"], + shift_range=( + timezone.datetime(year, 8, 27, 14, 0, tzinfo=timezone.utc), + timezone.datetime(year, 8, 27, 20, 0, tzinfo=timezone.utc), + ), + people_required=1, + ) + + def create_camp_info_categories(self, camp, teams): + categories = {} + year = camp.camp.lower.year + self.output("Creating infocategories for {}...".format(year)) + categories["when"] = InfoCategory.objects.create( + team=teams["orga"], headline="When is BornHack happening?", anchor="when" + ) + categories["travel"] = InfoCategory.objects.create( + team=teams["orga"], headline="Travel Information", anchor="travel" + ) + categories["sleep"] = InfoCategory.objects.create( + team=teams["orga"], headline="Where do I sleep?", anchor="sleep" + ) + + return categories + + def create_camp_info_items(self, camp, categories): + year = camp.camp.lower.year + self.output("Creating infoitems for {}...".format(year)) + InfoItem.objects.create( + category=categories["when"], + headline="Opening", + anchor="opening", + body="BornHack {} starts saturday, august 27th, at noon (12:00). It will be possible to access the venue before noon if for example you arrive early in the morning with the ferry. But please dont expect everything to be ready before noon :)".format( + year + ), + ) + InfoItem.objects.create( + category=categories["when"], + headline="Closing", + anchor="closing", + body="BornHack {} ends saturday, september 3rd, at noon (12:00). Rented village tents must be empty and cleaned at this time, ready to take down. Participants must leave the site no later than 17:00 on the closing day (or stay and help us clean up).".format( + year + ), + ) + InfoItem.objects.create( + category=categories["travel"], + headline="Public Transportation", + anchor="public-transportation", + body=self.output_fake_md_description(), + ) + InfoItem.objects.create( + category=categories["travel"], + headline="Bus to and from BornHack", + anchor="bus-to-and-from-bornhack", + body="PROSA, the union of IT-professionals in Denmark, has set up a great deal for BornHack attendees travelling from Copenhagen to BornHack. For only 125kr, about 17 euros, you can be transported to the camp on opening day, and back to Copenhagen at the end of the camp!", + ) + InfoItem.objects.create( + category=categories["when"], + headline="Driving and Parking", + anchor="driving-and-parking", + body=self.output_fake_md_description(), + ) + InfoItem.objects.create( + category=categories["sleep"], + headline="Camping", + anchor="camping", + body="BornHack is first and foremost a tent camp. You need to bring a tent to sleep in. Most people go with some friends and make a camp somewhere at the venue. See also the section on Villages - you might be able to find some likeminded people to camp with.", + ) + InfoItem.objects.create( + category=categories["sleep"], + headline="Cabins", + anchor="cabins", + body="We rent out a few cabins at the venue with 8 beds each for people who don't want to sleep in tents for some reason. A tent is the cheapest sleeping option (you just need a ticket), but the cabins are there if you want them.", + ) + + def create_camp_feedback(self, camp, users): + year = camp.camp.lower.year + self.output("Creating feedback for {}...".format(year)) + Feedback.objects.create( + camp=camp, user=users[1], feedback="Awesome event, will be back next year" + ) + Feedback.objects.create( + camp=camp, + user=users[3], + feedback="Very nice, though a bit more hot water would be awesome", + ) + Feedback.objects.create( + camp=camp, user=users[5], feedback="Is there a token here?" + ) + Feedback.objects.create( + camp=camp, user=users[9], feedback="That was fun. Thanks!" + ) + + def create_camp_rides(self, camp, users): + year = camp.camp.lower.year + self.output("Creating rides for {}...".format(year)) + Ride.objects.create( + camp=camp, + user=users[1], + seats=2, + location="From Copenhagen", + when=timezone.datetime(year, 8, 27, 12, 0, tzinfo=timezone.utc), + description="I have space for two people and a little bit of luggage", + ) + Ride.objects.create( + camp=camp, + user=users[1], + seats=2, + location="To Copenhagen", + when=timezone.datetime(year, 9, 4, 12, 0, tzinfo=timezone.utc), + description="I have space for two people and a little bit of luggage", + ) + Ride.objects.create( + camp=camp, + user=users[4], + seats=1, + location="From Aarhus", + when=timezone.datetime(year, 8, 27, 12, 0, tzinfo=timezone.utc), + description="I need a ride and have a large backpack", + ) + + def create_camp_cfp(self, camp): + year = camp.camp.lower.year + self.output("Creating CFP for {}...".format(year)) + camp.call_for_participation_open = True + camp.call_for_participation = "Please give a talk at Bornhack {}...".format( + year + ) + + def create_camp_cfs(self, camp): + year = camp.camp.lower.year + self.output("Creating CFS for {}...".format(year)) + camp.call_for_sponsors_open = True + camp.call_for_sponsors = "Please give us ALL the money so that we can make Bornhack {} the best ever!".format( + year + ) + + def create_camp_sponsor_tiers(self, camp): + tiers = {} + year = camp.camp.lower.year + self.output("Creating sponsor tiers for {}...".format(year)) + tiers["platinum"] = SponsorTier.objects.create( + name="Platinum sponsors", + description="- 10 tickets\n- logo on website\n- physical banner in the speaker's tent\n- thanks from the podium\n- recruitment area\n- sponsor meeting with organizers\n- promoted HackMe\n- sponsored social event", + camp=camp, + weight=0, + tickets=10, + ) + tiers["gold"] = SponsorTier.objects.create( + name="Gold sponsors", + description="- 10 tickets\n- logo on website\n- physical banner in the speaker's tent\n- thanks from the podium\n- recruitment area\n- sponsor meeting with organizers\n- promoted HackMe", + camp=camp, + weight=1, + tickets=10, + ) + tiers["silver"] = SponsorTier.objects.create( + name="Silver sponsors", + description="- 5 tickets\n- logo on website\n- physical banner in the speaker's tent\n- thanks from the podium\n- recruitment area\n- sponsor meeting with organizers", + camp=camp, + weight=2, + tickets=5, + ) + tiers["sponsor"] = SponsorTier.objects.create( + name="Sponsors", + description="- 2 tickets\n- logo on website\n- physical banner in the speaker's tent\n- thanks from the podium\n- recruitment area", + camp=camp, + weight=3, + tickets=2, + ) + + return tiers + + def create_camp_sponsors(self, camp, tiers): + year = camp.camp.lower.year + self.output("Creating sponsors for {}...".format(year)) + Sponsor.objects.create( + name="PROSA", + tier=tiers["platinum"], + description="Bus Trip", + logo_filename="PROSA-logo.png", + url="https://www.prosa.dk", + ) + Sponsor.objects.create( + name="DKUUG", + tier=tiers["platinum"], + description="Speakers tent", + logo_filename="DKUUGlogo.jpeg", + url="http://www.dkuug.dk/", + ) + Sponsor.objects.create( + name="LetsGo", + tier=tiers["silver"], + description="Shuttle", + logo_filename="letsgo.png", + url="https://letsgo.dk", + ) + Sponsor.objects.create( + name="Saxo Bank", + tier=tiers["gold"], + description="Cash Sponsorship", + logo_filename="saxobank.png", + url="https://home.saxo", + ) + Sponsor.objects.create( + name="CSIS", + tier=tiers["sponsor"], + description="Cash Sponsorship", + logo_filename="CSIS_PRI_LOGO_TURQUOISE_RGB.jpg", + url="https://csis.dk", + ) + + def create_camp_tokens(self, camp): + tokens = {} + year = camp.camp.lower.year + self.output("Creating tokens for {}...".format(year)) + tokens[0] = Token.objects.create( + camp=camp, + token=get_random_string(length=32), + category="Physical", + description="Token in the back of the speakers tent (in binary)", + ) + tokens[1] = Token.objects.create( + camp=camp, + token=get_random_string(length=32), + category="Internet", + description="Twitter", + ) + tokens[2] = Token.objects.create( + camp=camp, + token=get_random_string(length=32), + category="Website", + description="Token hidden in the X-Secret-Token HTTP header on the BornHack website", + ) + tokens[3] = Token.objects.create( + camp=camp, + token=get_random_string(length=32), + category="Physical", + description="Token in infodesk (QR code)", + ) + tokens[4] = Token.objects.create( + camp=camp, + token=get_random_string(length=32), + category="Physical", + description="Token on the back of the BornHack {} badge".format(year), + ) + tokens[5] = Token.objects.create( + camp=camp, + token=get_random_string(length=32), + category="Website", + description="Token hidden in EXIF data in the logo posted on the website sunday", + ) + + return tokens + + def create_camp_token_finds(self, camp, tokens, users): + year = camp.camp.lower.year + self.output("Creating token finds for {}...".format(year)) + TokenFind.objects.create(token=tokens[3], user=users[4]) + TokenFind.objects.create(token=tokens[5], user=users[4]) + TokenFind.objects.create(token=tokens[2], user=users[7]) + TokenFind.objects.create(token=tokens[1], user=users[3]) + TokenFind.objects.create(token=tokens[4], user=users[2]) + TokenFind.objects.create(token=tokens[5], user=users[6]) + for i in range(0, 6): + TokenFind.objects.create(token=tokens[i], user=users[1]) + + def output(self, message): + self.stdout.write( + "%s: %s" % (timezone.now().strftime("%Y-%m-%d %H:%M:%S"), message) + ) + + def handle(self, *args, **options): + self.output("----------[ Global stuff ]----------") + + camps = self.create_camps() + users = self.create_users() + + self.create_news() + + event_types = self.create_event_types() + + product_categories = self.create_product_categories() + + global_products = self.create_global_products(product_categories) + + for (camp, read_only) in camps: year = camp.camp.lower.year - self.output("Creating tickettypes for {}...".format(year)) - adult_full_week = TicketType.objects.create( - name="Adult Full Week", camp=camp - ) - adult_one_day = TicketType.objects.create(name="Adult One Day", camp=camp) - child_full_week = TicketType.objects.create( - name="Child Full Week", camp=camp - ) - child_one_day = TicketType.objects.create(name="Child One Day", camp=camp) - - name = "BornHack {} Standard ticket".format(year) - ticket1 = Product.objects.create( - name=name, - description="A ticket", - price=1200, - category=tickets, - available_in=( - timezone.datetime(year, 1, 1, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 12, 20, 12, 0, tzinfo=timezone.utc), - ), - slug="{}".format(slugify(name)), - ticket_type=adult_full_week, + self.output( + self.style.SUCCESS("----------[ Bornhack {} ]----------".format(year)) ) - name = "BornHack {} Hacker ticket".format(year) - ticket2 = Product.objects.create( - name=name, - description="Another ticket", - price=1337, - category=tickets, - available_in=( - timezone.datetime(year, 1, 1, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 12, 20, 12, 0, tzinfo=timezone.utc), - ), - slug="{}".format(slugify(name)), - ticket_type=adult_full_week, - ) + if year < 2020: + ticket_types = self.create_camp_ticket_types(camp) - self.output("Creating orders...") - order0 = Order.objects.create( - user=user1, payment_method="cash", open=None, paid=True - ) - order0.orderproductrelation_set.create(product=ticket1, quantity=1) - order0.orderproductrelation_set.create(product=tent1, quantity=1) - order0.mark_as_paid(request=None) + camp_products = self.create_camp_products( + camp, product_categories, ticket_types + ) - order1 = Order.objects.create(user=user2, payment_method="cash", open=None) - order1.orderproductrelation_set.create(product=ticket1, quantity=1) - order1.orderproductrelation_set.create(product=tent2, quantity=1) - order1.mark_as_paid(request=None) + orders = self.create_orders(users, global_products, camp_products) - order2 = Order.objects.create(user=user3, payment_method="cash", open=None) - order2.orderproductrelation_set.create(product=ticket2, quantity=1) - order2.orderproductrelation_set.create(product=ticket1, quantity=1) - order2.orderproductrelation_set.create(product=tent2, quantity=1) - order2.mark_as_paid(request=None) + tracks = self.create_camp_tracks(camp) - order3 = Order.objects.create(user=user4, payment_method="cash", open=None) - order3.orderproductrelation_set.create(product=product0, quantity=1) - order3.orderproductrelation_set.create(product=ticket2, quantity=1) - order3.orderproductrelation_set.create(product=tent1, quantity=1) - order3.mark_as_paid(request=None) + locations = self.create_camp_locations(camp) - self.output("Creating eventtracks for {}...".format(year)) - track = EventTrack.objects.create( - camp=camp, name="BornHack", slug=camp.slug - ) + self.create_camp_news(camp) - self.output("Creating eventlocations for {}...".format(year)) - speakers_tent = EventLocation.objects.create( - name="Speakers Tent", slug="speakers-tent", icon="comment", camp=camp - ) - workshop_room = EventLocation.objects.create( - name="Workshop rooms", - slug="workshop-rooms", - icon="briefcase", - camp=camp, - ) - bar_area = EventLocation.objects.create( - name="Bar Area", slug="bar-area", icon="glass", camp=camp - ) - food_area = EventLocation.objects.create( - name="Food Area", slug="food-area", icon="cutlery", camp=camp - ) + events = self.create_camp_events(camp, tracks, event_types) - self.output("Creating news for {}...".format(year)) - NewsItem.objects.create( - title="Welcome to {}".format(camp.title), - content="news body here with html support", - published_at=timezone.datetime(year, 8, 27, 12, 0, tzinfo=timezone.utc), - ) - NewsItem.objects.create( - title="{} is over".format(camp.title), - content="news body here", - published_at=timezone.datetime(year, 9, 4, 12, 0, tzinfo=timezone.utc), - ) + speakers = self.create_camp_speakers(camp, events) - self.output("Creating events for {}...".format(year)) - ev1 = Event.objects.create( - title="Developing the BornHack website", - abstract="abstract here, bla bla bla", - event_type=talk, - track=track, - ) - ev2 = Event.objects.create( - title="State of the world", - abstract="abstract here, bla bla bla", - event_type=keynote, - track=track, - ) - ev3 = Event.objects.create( - title="Welcome to bornhack!", - abstract="abstract here, bla bla bla", - event_type=talk, - track=track, - ) - ev4 = Event.objects.create( - title="bar is open", - abstract="the bar is open, yay", - event_type=facility, - track=track, - ) - ev5 = Event.objects.create( - title="Network something", - abstract="abstract here, bla bla bla", - event_type=talk, - track=track, - ) - ev6 = Event.objects.create( - title="State of outer space", - abstract="abstract here, bla bla bla", - event_type=talk, - track=track, - ) - ev9 = Event.objects.create( - title="The Alternative Welcoming", - abstract="Why does The Alternative support BornHack? Why does The Alternative think IT is an overlooked topic? A quick runt-hrough of our program and workshops. We will bring an IT political debate to both the stage and the beer tents.", - event_type=talk, - track=track, - ) - ev10 = Event.objects.create( - title="Words and Power - are we making the most of online activism?", - abstract="For years, big names like Ed Snowden and Chelsea Manning have given up their lives in order to protect regular people like you and me from breaches of our privacy. But we are still struggling with getting people interested in internet privacy. Why is this, and what can we do? Using experience from communicating privacy issues on multiple levels for a couple of years, I have encountered some deep seated issues in the way we talk about what privacy means. Are we good enough at letting people know whats going on?", - event_type=keynote, - track=track, - ) - ev11 = Event.objects.create( - title="r4d1o hacking 101", - abstract="Learn how to enable the antenna part of your ccc badge and get started with receiving narrow band FM. In the workshop you will have the opportunity to sneak peak on the organizers radio communications using your SDR. If there is more time we will look at WiFi radar or your protocol of choice.", - event_type=workshop, - track=track, - ) - ev12 = Event.objects.create( - title="Introduction to Sustainable Growth in a Digital World", - abstract="Free Choice is the underestimated key to secure value creation in a complex economy, where GDP-models only measure commercial profit and ignore the environment. We reconstruct the model thinking about Utility, Production, Security and Environment around the 5 Criteria for Sustainability.", - event_type=workshop, - track=track, - ) - ev13 = Event.objects.create( - title="American Fuzzy Lop and Address Sanitizer", - abstract=""" -We have powerful and easy to use tools that can vastly improve the quality and security of the code we use everyday. + self.create_camp_scheduling(camp, events, locations) -Code written in C and C++ is often riddled with bugs in the memory management. Out of bounds accesses, use after free errors and other issues can hamper the security and stability of applications. Unfortunately many free software developers don't use freely available tools that easily allow finding and eliminating many of these bugs. The talk will encourage developers to change that and integrate these tools into their development process. + self.create_camp_villages(camp, users) -Slides: [https://www.int21.de/slides/bornhack2016-fuzzing/](https://www.int21.de/slides/bornhack2016-fuzzing/) - """, - event_type=talk, - track=track, - ) - ev14 = Event.objects.create( - title="PGP Keysigning Party", - abstract=""" -Let's verify each other's digital PGP keys at BornHack so that we can authenticate each other when we are not together at the island. + teams = self.create_camp_teams(camp) -For people who haven't attended a PGP keysigning party before, we will guide you through it + self.create_camp_team_tasks(camp, teams) -### What do I need to bring? + team_memberships = self.create_camp_team_memberships(camp, teams, users) -1. Bring the output of `gpg --fingerprint $YOUR_KEY_ID` on some pieces of paper to hand out. -2. (Optional) Bring some government-issued identification paper (passport, drivers license, etc.). The ID should contain a picture of yourself. You can leave this out, but then it will be a bit harder for others to verify your key properly. - """, - event_type=workshop, - track=track, - ) - ev15 = Event.objects.create( - title="Bluetooth Low Energy", - abstract=""" -BLE provides versatile wireless communication at a very low -power consumption, especially compared to classic Bluetooth -and WiFi. + self.create_camp_team_shifts(camp, teams, team_memberships) -It has a wide range of uses where proximity detection is used -for a lot of applications such as alerting when a keychain -goes out of range or requesting alerts from lost objects. Among -consumer products, Apple iBeacons is a notable application of -the technology. However, it is also used for human input devices -such as mice and keyboards as well as various forms of sensors, -e.g. temperature, heart rate, etc. + info_categories = self.create_camp_info_categories(camp, teams) -BLE enables devices to run off coincell batteries for years -while retaining connections or doing periodic broadcasting. -This makes the technology appealing for the maker community -for applications that are power-constrained, e.g. due to having -a limited power-budget (say, running off a small PV-cell) or -running off a battery. + self.create_camp_info_items(camp, info_categories) -This talk explains how the low power consumption is achieved, -what the possible topologies are, and how this affects the types -of applications you can build on top. Finally, a low-level -demonstration of interfacing with a BLE controller is performed. - """, - event_type=talk, - track=track, - ) - ev16 = Event.objects.create( - title="TLS attacks and the burden of faulty TLS implementations", - abstract=""" -TLS is by far the most important cryptographic protocol in use today. -In recent years TLS received much more attention from security -researchers. Implementation errors like Heartbleed and protocol bugs -like BEAST, Lucky Thirteen, DROWN and many more have made headlines. + self.create_camp_feedback(camp, users) -Faulty implementations can enable attacks. In some cases they can even -be a security risk for uninvolved third parties and endanger the whole -TLS ecosystem. Especially so-called Enterprise devices that have their -own TLS stack are often a reason for concern. + self.create_camp_rides(camp, users) -The speaker will give an overview of implementation errors that -happened in various TLS stacks and will shed light on this -underappreciated problem. + self.create_camp_cfp(camp) -Slides: [https://www.int21.de/slides/bornhack2016-tls/](https://www.int21.de/slides/bornhack2016-tls/) - """, - event_type=talk, - track=track, - ) - ev17 = Event.objects.create( - title="State of the Network", - abstract="Come and meet the network team who will talk about the design and operation of the network at BornHack.", - event_type=talk, - track=track, - ) - ev18 = Event.objects.create( - title="Running Exit Nodes in the North", - abstract=""" -Tor is free software and an open network that helps you defend against -traffic analysis, a form of network surveillance that threatens personal -freedom and privacy, confidential business activities and relationships, -and state security. + self.create_camp_cfs(camp) -People can donate their bandwidth to the Tor network and support human -rights. Many people in Finland have done this. + sponsor_tiers = self.create_camp_sponsor_tiers(camp) -Especially Tor network needs fast exit nodes which are final nodes before -traffic reaches its destination. Because Tor traffic exits through these -relays, the IP address of the exit relay is interpreted as the source of -the traffic. + self.create_camp_sponsors(camp, sponsor_tiers) -If a malicious user employs the Tor network to do something that might be -objectionable or illegal, the exit relay may take the blame. People who run -exit relays should be prepared to deal with complaints, copyright takedown -notices, and the possibility that their servers may attract the attention -of law enforcement agencies. + tokens = self.create_camp_tokens(camp) -In Finland, Juha Nurmi has been establishing good relationships with ISPs -and law enforcement agencies to keep Finnish exit nodes online. - """, - event_type=talk, - track=track, - ) - ev19 = Event.objects.create( - title="Hacker Jeopardy Qualifier", - abstract="Hacker Jeopardy qualifying", - event_type=slack, - track=track, - ) - ev20 = Event.objects.create( - title="Hacker Jeopardy Finals", - abstract="Hacker Jeopardy Finals between the winners of the qualifying games", - event_type=slack, - track=track, - ) - ev21 = Event.objects.create( - title="Incompleteness Phenomena in Mathematics: From Kurt Gödel to Harvey Friedman", - abstract=""" -In the first half of the 20th century the dreams of a complete and -consistent formalization of mathematics was destroyed, when Kurt Gödel -proved the existence of true but unprovable sentences in every -reasonable formalization of mathematics. + self.create_camp_token_finds(camp, tokens, users) + else: + self.output("Not creating anything for this year yet") -However, the explicit sentence constructed in the proof was tailored to -cause trouble and therefore was not of much interest to mathematicians -in general. Since then various incompleteness phenomena have been -discovered and many of these (relative) unprovable sentences are of genuine mathematical interest. In recent years Harvey Friedman have taken this enterprise to a new level by constructing sentences about "low level" mathematics and showed that these sentences are provably equivalent to the consistency of axiomatic systems far stronger than classical set theory (ZFC). In this talk I will try to introduce concepts of mathematical logic together with some highlights in the history of incompleteness phenomena and discuss the philosophical implications of these. + camp.read_only = read_only + camp.save() -Note that these (early 20th century) developments also play an important role in developing the theoretical computer. - """, - event_type=talk, - track=track, - ) - ev22 = Event.objects.create( - title="Infocalypse Now - and how to Survive It?", - abstract=""" -Digitalization is on everybodys mind - and so is control and registration -of citizens. States and businesses all choose sadly unsecure -data-silo-systems and piles up sensitive data without securing anything. -Critical Infrastructure is privatized and sold off and secure, analog -systems are being torn down in the name of progress. -Its an evolving Infocalypse, where all info can be manipulated, stolen and -used, our money system, personal data and administrations are doomed in a -world of greedy blackhats, cyberwarfare-troops, autonomous drones, -herfbombs, solarstorms and intelligence agencies on steroids -The Beast is unleashed, can it be stopped, or is it anyone for him self? - """, - event_type=keynote, - track=track, - ) - ev23 = Event.objects.create( - title="Liquid Democracy (Introduction and Debate)", - abstract=""" -A lot has happened ever since the German pirates developed the first visions about a dynamic representational democracy. Google and other big players have experimented with the disciplines, and the idea of a more modern form of democracy has grown steadily. - -Monday will primarily be focused around The Alternatives experiment with Liquid Democracy and a constructive debate about how liquid democracy can improve The Alternative. Rolf Bjerre leads the process. - """, - event_type=talk, - track=track, - ) - ev24 = Event.objects.create( - title="Badge Workshop", - abstract=""" -In this workshop you can learn how to solder and get help assembling your badge. We will have soldering irons and other tools to help things along. You can also discuss your ideas for badge hacks and modifications with the other participants and the host, Thomas Flummer. - """, - event_type=workshop, - track=track, - ) - ev25 = Event.objects.create( - title="Checking a Distributed Hash Table for Correctness", - abstract=""" -Distributed Hash Tables are used as name-lookups in large decentralized -distributed systems -such as peer-to-peer networks and loosely connected machine clusters. -Correctness is -complicated by their distributed nature. This talk presents an -implementation of one such DHT, -written in Erlang, based on the Kademlia data structure. Its unique feature -is that it comes equipped with -a full QuickCheck specification, which semi-formally verifies its correct -behaviour through random -test generation. - -The talk focuses on the test aspect of the system, and how one builds -fairly large QuickCheck -specifications for real-world systems, in particular by slicing a large -specification into isolated -parts and then reassembling those parts into a full model. It is intended -to give people an overview -of how to attack larger code bases with (semi-) formal methods. - """, - event_type=talk, - track=track, - ) - ev26 = Event.objects.create( - title="GraphQL - A Data Language", - abstract=""" -GraphQL is a query-language for data, intended for the modern internet -clients on the web and -inside mobile phones, invented inside Facebook around 2012, it is currently -in a draft specification -phase with several open source implementations of the underlying ideas. - -The main feature of GraphQL is a shift away from RESTful services where all -of the query -declaration is on the server side, to one where the client is in control -of declaring what it wants. -The result is a system which is easy to work with for the front-end -developer. GraphQL also -supports backward compatibility to earlier client versions. All while being -able to maintain a -security level at least as good as REST. On the server side, GraphQL -provides much the same -benefits, acting as a protocol and contract between the server and client. - -This talk presents GraphQL itself, and also presents how one goes about -building an implementation -of the language. The running example is a GraphQL compiler written for -Erlang. - """, - event_type=talk, - track=track, - ) - ev27 = Event.objects.create( - title="Visualisation of Public Datasets", - abstract=""" -At the same time as society is getting more complex, the amount of data is growing exponentially. How are everyday citizens to relate to National budgets used in the media? I am going to talk about one of the ways I think will make it easier to understand the datasets used in the media. - -I will present some portals where it is possible to get public datasets. Afterwards we will reflect about the use of these datasets. - -Towards the end we will open up to debate about how to use these resources or if there are other solutions. - """, - event_type=workshop, - track=track, - ) - ev28 = Event.objects.create( - title="Local delicacies", - abstract="Come taste delicacies from bornholm", - event_type=facility, - track=track, - ) - ev29 = Event.objects.create( - title="Local delicacies from the world", - abstract="An attempt to create an event where we all prepare local delicacies for each other", - event_type=facility, - track=track, - ) - - self.output("Creating speakers for {}...".format(year)) - sp1 = Speaker.objects.create( - name="Henrik Kramse", - biography="Henrik is an internet samurai working in internet and security around the world.", - slug="henrik-kramshj", - camp=camp, - email="email@email.lol", - ) - sp1.events.add(ev5) - sp2 = Speaker.objects.create( - name="Thomas Tykling", - biography="random danish hacker", - slug="thomas-tykling", - camp=camp, - email="email@email.lol", - ) - sp2.events.add(ev3, ev1) - sp3 = Speaker.objects.create( - name="Alex Ahf", - biography="functional alcoholic", - slug="alex-ahf", - camp=camp, - email="email@email.lol", - ) - sp3.events.add(ev4, ev2) - sp4 = Speaker.objects.create( - name="Jesper Arp", - biography="Representative from The Alternative with focus in data visualization.", - slug="jesper-arp", - camp=camp, - email="email@email.lol", - ) - sp4.events.add(ev9, ev27) - sp5 = Speaker.objects.create( - name="Rolf Bjerre", - biography="The green pirate", - slug="rolf-bjerre", - camp=camp, - email="email@email.lol", - ) - sp5.events.add(ev9, ev23) - sp6 = Speaker.objects.create( - name="Emma Holten", - biography="Emma Holten is a feminist and human rights activist. She is co-founder and editor of the standard critical magazine Friktion and also a student at the University of Copenhagen. She speaks in both national and global contexts of feminism, digital activism and why privacy on the internet is crucial to a democracy, where everyone is equal.", - slug="emma-holten", - camp=camp, - email="email@email.lol", - ) - sp6.events.add(ev10) - sp7 = Speaker.objects.create( - name="Christoffer Jerkeby", - biography="Hacker and phone phreaker from Stockholm bent on radio. Researching security and privacy in wireless protocols.", - slug="christoffer-jerkeby", - camp=camp, - email="email@email.lol", - ) - sp7.events.add(ev11) - sp8 = Speaker.objects.create( - name="Stephan Engberg", - biography="Stephan Engberg is a Computer Scientist specializing in Innovation Strategist working with Digital Business when he realized the Digital World is designed through our approach to security models and economic models. He then dedicated himself to Privacy/Security by Design in Open Business Innovation making numerous breakthroughs in security and engaged in EU research activities he was e.g. member of the Strategic Advisory Board for FP7 Security Research Roadmapping and started manufacturing of RFID computer chips based on Privacy by Design with zero-knowledge based computing in passive chips without battery or ultra-low memory and computational capabilities. In 2003, he was selected by an a transatlantic panel of researchers in ethics as a Moral Example in the Computer Profession.", - slug="stephan-engberg", - camp=camp, - email="email@email.lol", - ) - sp8.events.add(ev12) - sp9 = Speaker.objects.create( - name="Hanno Böck", - biography=""" -Hanno Böck started the Fuzzing Project in 2014 as an effort to improve -the security of free software code. In May the Linux Foundation's Core -Infrastructure Initiative decided to fund this work. He is also -working as a freelance journalist and regularly writes about IT -security issues for various publications. He is the author of the -monthly Bulletproof TLS Newsletter. - """, - slug="hanno-bock", - camp=camp, - email="email@email.lol", - ) - sp9.events.add(ev13, ev16) - sp10 = Speaker.objects.create( - name="Ximin Luo", - biography=""" -I'm Ximin Luo, a Debian Developer and security research engineer. I work on -secure protocols and decentralized systems. I prefer to use high-level checked -languages such as Rust, OCaml, or Haskell. I work for the Reproducible Builds -project and have previously worked for MEGA, Tor, Google and Freenet. - -I also like music, cooking, sci-fi and cats, in an order indistinguishable from -a truly random sequence by a polynomial-time-bounded computational adversary. - """, - slug="ximin-luo", - camp=camp, - email="email@email.lol", - ) - sp10.events.add(ev14) - sp11 = Speaker.objects.create( - name="Michael Knudsen", - biography=""" -Michael has been involved in various open source-related projects. -His dayjob involves writing firmware for a BT/wifi controller -for a semiconductor company. - """, - slug="michael-knudsen", - camp=camp, - email="email@email.lol", - ) - sp11.events.add(ev15) - sp12 = Speaker.objects.create( - name="BornHack Network Team", - biography="The team you won't notice if everything goes as it should. Please bring them rum or beer if they look too stressed.", - slug="bornhack-network-team", - camp=camp, - email="email@email.lol", - ) - sp12.events.add(ev17) - sp13 = Speaker.objects.create( - name="Juha Nurmi", - biography=""" -Juha Nurmi (age 28) is the founder and project -leader of the Ahmia search engine project. He is a security researcher and -has been involved in numerous projects funded by both the commercial -and government spheres, including DARPA Memex project in the Silicon -Valley. Juha is also a noted lecturer and public speaker. Juha's work on -Ahmia has been in part sponsored by the Google Summer of Code. - """, - slug="juha-nurmi", - camp=camp, - email="email@email.lol", - ) - sp13.events.add(ev18) - sp14 = Speaker.objects.create( - name="Lasse Andersen", - biography=""" -My educational background is a masters degree in philosophy & -mathematics and a PhD in applied mathematics and road engineering. -My personal interests cover philosophy of IT, philosophy of math, -programming, machine learning, road engineering. - -Also, I enjoy nature quite a bit. Presently, I work at the Danish Road Directorate with rolling resistance modelling and pavement management as the main focus. Besides doing a lot of programming at work (primarily Python) I also experiment with Erlang in my spare time trying to build peer2peer software. - """, - slug="lasse-andersen", - camp=camp, - email="email@email.lol", - ) - sp14.events.add(ev21) - sp15 = Speaker.objects.create( - name="Anders Kjærulff", - biography=""" -Anders Kjærulff is a jounalist, poet, technology-critic and radiohost -with a weekly, one hour radioshow on privacy and data protection. He is -currently working on a dystopic book about the end of all privacy and the -dim future, that lies ahead. - -Website: [aflyttet.dk](https://aflyttet.dk) - """, - slug="anders-kjrulff", - camp=camp, - email="email@email.lol", - ) - sp15.events.add(ev22) - sp16 = Speaker.objects.create( - name="Thomas Flummer", - biography=""" -Thomas is an electronics engineer, though he is mostly doing software development in his professional life. For the past 7 years Thomas has been a member of the hackerspace Labitat, where he has been doing various projects, mostly with electronics, 3D printing and video documentation. - """, - slug="thomas-flummer", - camp=camp, - email="email@email.lol", - ) - sp16.events.add(ev24) - sp17 = Speaker.objects.create( - name="Jesper Louis Andersen", - biography=""" -Jesper Louis Andersen bridges the gap between theory and practice. He has a -curiosity for -programming language theory, math, and logic, but dabbles in many other -fields of computer -science as well. His main interest is to move state-of-the-art computer -science research into -real world use whenever possible. His dayjob involves functional -programming for a danish startup. - """, - slug="jesper-louis-andersen", - camp=camp, - email="email@email.lol", - ) - sp17.events.add(ev25, ev26) - - self.output("Creating eventinstances for {}...".format(year)) - EventInstance.objects.create( - event=ev3, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 27, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 27, 13, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev1, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 28, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 28, 13, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev2, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 29, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 29, 13, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev4, - location=bar_area, - when=( - timezone.datetime(year, 8, 27, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 28, 5, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev4, - location=bar_area, - when=( - timezone.datetime(year, 8, 28, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 29, 5, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev4, - location=bar_area, - when=( - timezone.datetime(year, 8, 29, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 30, 5, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev4, - location=bar_area, - when=( - timezone.datetime(year, 8, 30, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 31, 5, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev4, - location=bar_area, - when=( - timezone.datetime(year, 8, 31, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 9, 1, 5, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev4, - location=bar_area, - when=( - timezone.datetime(year, 9, 1, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 9, 2, 5, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev4, - location=bar_area, - when=( - timezone.datetime(year, 9, 2, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 9, 3, 5, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev5, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 28, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 28, 13, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev6, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 29, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 29, 13, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev9, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 30, 11, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 30, 11, 30, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev10, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 30, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 30, 13, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev12, - location=workshop_room, - when=( - timezone.datetime(year, 8, 30, 9, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 30, 11, 30, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev11, - location=workshop_room, - when=( - timezone.datetime(year, 8, 31, 14, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 31, 16, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev18, - location=speakers_tent, - when=( - timezone.datetime(year, 9, 2, 14, 0, tzinfo=timezone.utc), - timezone.datetime(year, 9, 2, 15, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev17, - location=speakers_tent, - when=( - timezone.datetime(year, 9, 2, 16, 0, tzinfo=timezone.utc), - timezone.datetime(year, 9, 2, 17, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev15, - location=speakers_tent, - when=( - timezone.datetime(year, 9, 1, 15, 0, tzinfo=timezone.utc), - timezone.datetime(year, 9, 1, 16, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev14, - location=workshop_room, - when=( - timezone.datetime(year, 8, 31, 21, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 31, 22, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev16, - location=speakers_tent, - when=( - timezone.datetime(year, 9, 1, 14, 0, tzinfo=timezone.utc), - timezone.datetime(year, 9, 1, 15, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev13, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 31, 17, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 31, 18, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev19, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 30, 22, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 30, 23, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev19, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 29, 22, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 29, 23, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev19, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 28, 22, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 28, 23, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev19, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 31, 22, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 31, 23, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev19, - location=speakers_tent, - when=( - timezone.datetime(year, 9, 1, 22, 0, tzinfo=timezone.utc), - timezone.datetime(year, 9, 1, 23, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev20, - location=speakers_tent, - when=( - timezone.datetime(year, 9, 2, 20, 0, tzinfo=timezone.utc), - timezone.datetime(year, 9, 2, 22, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev21, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 28, 12, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 28, 13, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev22, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 28, 18, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 28, 19, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev23, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 29, 9, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 29, 11, 30, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev24, - location=workshop_room, - when=( - timezone.datetime(year, 8, 29, 20, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 29, 22, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev25, - location=speakers_tent, - when=( - timezone.datetime(year, 9, 1, 17, 0, tzinfo=timezone.utc), - timezone.datetime(year, 9, 1, 18, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev26, - location=speakers_tent, - when=( - timezone.datetime(year, 8, 30, 11, 0, tzinfo=timezone.utc), - timezone.datetime(year, 8, 30, 12, 0, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev26, - location=speakers_tent, - when=( - timezone.datetime(year, 9, 1, 11, 45, tzinfo=timezone.utc), - timezone.datetime(year, 9, 1, 12, 30, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev28, - location=food_area, - when=( - timezone.datetime(year, 9, 1, 18, 30, tzinfo=timezone.utc), - timezone.datetime(year, 9, 1, 21, 30, tzinfo=timezone.utc), - ), - ) - EventInstance.objects.create( - event=ev29, - location=food_area, - when=( - timezone.datetime(year, 8, 29, 18, 30, tzinfo=timezone.utc), - timezone.datetime(year, 8, 29, 23, 30, tzinfo=timezone.utc), - ), - ) - - self.output("Creating villages for {}...".format(year)) - Village.objects.create( - contact=user1, - camp=camp, - name="Baconsvin", - slug="baconsvin", - description="The camp with the doorbell-pig! Baconsvin is a group of happy people from Denmark doing a lot of open source, and are always happy to talk about infosec, hacking, BSD, and much more. A lot of the organizers of BornHack live in Baconsvin village. Come by and squeeze the pig and sign our guestbook!", - ) - Village.objects.create( - contact=user2, - camp=camp, - name="NetworkWarriors", - slug="networkwarriors", - description="We will have a tent which house the NOC people, various lab equipment people can play with, and have fun. If you want to talk about networking, come by, and if you have trouble with the Bornhack network contact us.", - ) - Village.objects.create( - contact=user3, - camp=camp, - name="TheCamp.dk", - slug="the-camp", - description="This village is representing TheCamp.dk, an annual danish tech camp held in July. The official subjects for this event is open source software, network and security. In reality we are interested in anything from computers to illumination soap bubbles and irish coffee", - ) - - self.output("Creating teams for {}...".format(year)) - orga_team = Team.objects.create( - name="Orga", - description="The Orga team are the main organisers. All tasks are Orga responsibility until they are delegated to another team", - camp=camp, - ) - noc_team = Team.objects.create( - name="NOC", - description="The NOC team is in charge of establishing and running a network onsite.", - camp=camp, - ) - bar_team = Team.objects.create( - name="Bar", - description="The Bar team plans, builds and run the IRL bar!", - camp=camp, - ) - - self.output("Creating TeamTasks for {}...".format(year)) - TeamTask.objects.create( - team=noc_team, - name="Setup private networks", - description="All the private networks need to be setup", - ) - TeamTask.objects.create( - team=noc_team, - name="Setup public networks", - description="All the public networks need to be setup", - ) - TeamTask.objects.create( - team=noc_team, - name="Deploy access points", - description="All access points need to be deployed", - ) - TeamTask.objects.create( - team=noc_team, - name="Deploy fiber cables", - description="We need the fiber deployed where necessary", - ) - TeamTask.objects.create( - team=bar_team, - name="List of booze", - description="A list of the different booze we need to have in the bar durng bornhack", - ) - TeamTask.objects.create( - team=bar_team, - name="Chairs", - description="We need a solution for chairs", - ) - TeamTask.objects.create( - team=bar_team, name="Taps", description="Taps must be ordered" - ) - TeamTask.objects.create( - team=bar_team, - name="Coffee", - description="We need to get some coffee for our coffee machine", - ) - TeamTask.objects.create( - team=bar_team, - name="Ice", - description="We need ice cubes and crushed ice in the bar", - ) - - self.output("Setting team members for {}...".format(year)) - # noc team - TeamMember.objects.create( - team=noc_team, user=user4, approved=True, responsible=True - ) - TeamMember.objects.create(team=noc_team, user=user1, approved=True) - TeamMember.objects.create(team=noc_team, user=user5, approved=True) - TeamMember.objects.create(team=noc_team, user=user6) - - # bar team - TeamMember.objects.create( - team=bar_team, user=user1, approved=True, responsible=True - ) - TeamMember.objects.create( - team=bar_team, user=user3, approved=True, responsible=True - ) - TeamMember.objects.create(team=bar_team, user=user2, approved=True) - TeamMember.objects.create(team=bar_team, user=user7, approved=True) - TeamMember.objects.create(team=bar_team, user=user8) - - # orga team - TeamMember.objects.create( - team=orga_team, user=user1, approved=True, responsible=True - ) - TeamMember.objects.create( - team=orga_team, user=user3, approved=True, responsible=True - ) - TeamMember.objects.create(team=orga_team, user=user8, approved=True) - TeamMember.objects.create(team=orga_team, user=user9, approved=True) - TeamMember.objects.create(team=orga_team, user=user4) - - self.output("Creating infocategories for {}...".format(year)) - info_cat1 = InfoCategory.objects.create( - team=orga_team, headline="When is BornHack happening?", anchor="when" - ) - info_cat2 = InfoCategory.objects.create( - team=orga_team, headline="Travel Information", anchor="travel" - ) - info_cat3 = InfoCategory.objects.create( - team=orga_team, headline="Where do I sleep?", anchor="sleep" - ) - - self.output("Creating infoitems for {}...".format(year)) - InfoItem.objects.create( - category=info_cat1, - headline="Opening", - anchor="opening", - body="BornHack 2016 starts saturday, august 27th, at noon (12:00). It will be possible to access the venue before noon if for example you arrive early in the morning with the ferry. But please dont expect everything to be ready before noon :)", - ) - InfoItem.objects.create( - category=info_cat1, - headline="Closing", - anchor="closing", - body="BornHack 2016 ends saturday, september 3rd, at noon (12:00). Rented village tents must be empty and cleaned at this time, ready to take down. Participants must leave the site no later than 17:00 on the closing day (or stay and help us clean up).", - ) - InfoItem.objects.create( - category=info_cat2, - headline="Public Transportation", - anchor="public-transportation", - body=""" -From/Via Copenhagen - -There are several ways to get to Bornholm from Copenhagen. A domestic plane departs from Copenhagen Airport, and you can get from Copenhagen Central station by either bus or train via Ystad or the Køge-Rønne ferry connection. - -Plane (very fast, most expensive) - You can check plane departures and book tickets at dat.dk. There are multiple departures daily. The flight takes approximately 25 minutes. -Via Ystad (quick, cheap and easy, crosses Sweden border) - You can drive over Øresundsbroen to Ystad or you can take the train/bus from Copenhagen Central Station. You can buy train and ferry ticket at dsb.dk (Type in "København H" and "Rønne Havn"). More information about the crossing. The crossing takes 1 hour 20 minutes. In total about 3 hours 15 minutes. Due to recent developments an ID (passport, drivers license or similar) is required when crossing the Denmark/Sweden border. -Via Køge (cheap, slow) - Take the S-train to Køge Station (you need an "all zones" ticket) or travel by car. The ferry terminal is within walking distance from the station. You can check out prices here. It takes approximately 1 hour to get to Køge. The crossing takes 5 hours 30 minutes. - -From Sweden/Malmö - -To get to Bornholm from Malmö you may take a train from Malmö to Ystad and the ferry from Ystad to Bornholm. - -Skånetrafiken runs trains from Malmö C to Ystad every 30 minutes. Trains leave at 08 and 38 minutes past the hour. Go to skanetrafiken for details. - -The ferry from Ystad to Rønne leaves four times per day. Morning: 08:30-09:50 Noon: 12:30-13:50 Afternoon: 16:30-17:50 Evening: 20:30-21:50 Booking the ferry tickets prior to departure can drastically reduce the price. See "Getting from Rønne to the Venue" final step. -From Abroad - -If you are going to BornHack from abroad you have different options as well. - -Berlin (Germany) - There are no public transport routes from Berlin to Mukran, Sassnitz ferry terminal on Saturdays, including Aug 27 and Sept 03 the Bornhack start/end dates. Your best bet is to get a train to Dubnitz, Sassnitz station. Unfortunately it is still 1.7km to the actual ferry terminal: map of route. There is a bus, but it only goes once a weekday at 12:28 and not at all on Weekends. You can of course take a taxi. Search for routes Berlin ‐ Dubnitz on bahn.de. At the time of writing, the best route is: - 08:45 Berlin Hbf → train with 2 changes, 50€ for a 2-way return ticket. - 12:52 Sassnitz → taxi, ~14€, 10 min. - 13:00 Mukran-Sassnitz ferry terminal - If you want to try your luck at a direct route to the ferry terminal, search for routes Berlin ‐ Sassnitz-Mukran Fährhafen on bahn.de or for routes Berlin ‐ Fährhafen Sassnitz on checkmybus.com. -Sassnitz (Germany) - There is a direct ferry taking cars going from Sassnitz ferry terminal which is 4km away from Sassnitz itself. The company is called BornholmerFærgen and the tickets cost 32€ (outgoing) and 25€ (return). It can also be booked from aferry.co.uk. The ferry departs for Bornholm on Aug 27 at 11:50, 13:30, and returns to Sassnitz on Sept 03 at 08:00, 09:00. Detailed timetable: English, Danish. -Kolobrzeg (Poland) - There is a passenger ferry from Kolobrzeg to Nexø havn. - -Getting from Rønne to the Venue - -The venue is 24km from Rønne. We will have a shuttle bus that will pick people up and take them to the venue. It is also possible to take a public bus to near the venue. Local taxis can also get you here. The company operating on Bornholm is called Dantaxi and the local phonenumber is +4556952301. - """, - ) - InfoItem.objects.create( - category=info_cat1, - headline="Bus to and from BornHack", - anchor="bus-to-and-from-bornhack", - body="PROSA, the union of IT-professionals in Denmark, has set up a great deal for BornHack attendees travelling from Copenhagen to BornHack. For only 125kr, about 17 euros, you can be transported to the camp on opening day, and back to Copenhagen at the end of the camp!", - ) - InfoItem.objects.create( - category=info_cat1, - headline="Driving and Parking", - anchor="driving-and-parking", - body=""" -A car is very convenient when bringing lots of equipment, and we know that hackers like to bring all the things. We welcome cars and vans at BornHack. We have ample parking space very close (less than 50 meters) to the main entrance. - -Please note that sleeping in the parking lot is not permitted. If you want to sleep in your car/RV/autocamper/caravan please contact us, and we will work something out. - """, - ) - InfoItem.objects.create( - category=info_cat3, - headline="Camping", - anchor="camping", - body="BornHack is first and foremost a tent camp. You need to bring a tent to sleep in. Most people go with some friends and make a camp somewhere at the venue. See also the section on Villages - you might be able to find some likeminded people to camp with.", - ) - InfoItem.objects.create( - category=info_cat3, - headline="Cabins", - anchor="cabins", - body="We rent out a few cabins at the venue with 8 beds each for people who don't want to sleep in tents for some reason. A tent is the cheapest sleeping option (you just need a ticket), but the cabins are there if you want them.", - ) + self.output("----------[ Finishing up ]----------") self.output("Adding event routing...") Routing.objects.create( - team=orga_team, + team=teams["orga"], eventtype=Type.objects.get(name="public_credit_name_changed"), ) Routing.objects.create( - team=orga_team, eventtype=Type.objects.get(name="ticket_created") + team=teams["orga"], eventtype=Type.objects.get(name="ticket_created") ) - self.output("marking 2016 and 2017 as read_only...") - camp2016.read_only = True - camp2016.save() - camp2017.read_only = True - camp2017.save() self.output("done!")