aboutsummaryrefslogtreecommitdiffstats
path: root/src/pharos_dashboard/celery.py
blob: f60f243388452ad32add658ce4b48aa40969c40a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
##############################################################################
# Copyright (c) 2016 Max Breitenfeldt and others.
#
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Apache License, Version 2.0
# which accompanies this distribution, and is available at
# http://www.apache.org/licenses/LICENSE-2.0
##############################################################################


import os

from celery import Celery

# set the default Django settings module for the 'celery' program.
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'pharos_dashboard.settings')

from django.conf import settings  # noqa

app = Celery('pharos_dashboard')

# Using a string here means the worker will not have to
# pickle the object when using Windows.
app.config_from_object('django.conf:settings')
app.autodiscover_tasks(lambda: settings.INSTALLED_APPS)


@app.task(bind=True)
def debug_task(self):
    print('Request: {0!r}'.format(self.request))
span> rsp; abi_ulong ss; /* top of stack page */ }; /* Maximum number of LDT entries supported. */ #define TARGET_LDT_ENTRIES 8192 /* The size of each LDT entry. */ #define TARGET_LDT_ENTRY_SIZE 8 #define TARGET_GDT_ENTRIES 16 #define TARGET_GDT_ENTRY_TLS_ENTRIES 3 #define TARGET_GDT_ENTRY_TLS_MIN 12 #define TARGET_GDT_ENTRY_TLS_MAX 14 #if 0 // Redefine this struct target_modify_ldt_ldt_s { unsigned int entry_number; abi_ulong base_addr; unsigned int limit; unsigned int seg_32bit:1; unsigned int contents:2; unsigned int read_exec_only:1; unsigned int limit_in_pages:1; unsigned int seg_not_present:1; unsigned int useable:1; unsigned int lm:1; }; #else struct target_modify_ldt_ldt_s { unsigned int entry_number; abi_ulong base_addr; unsigned int limit; unsigned int flags; }; #endif struct target_ipc64_perm { int key; uint32_t uid; uint32_t gid; uint32_t cuid; uint32_t cgid; unsigned short mode; unsigned short __pad1; unsigned short seq; unsigned short __pad2; abi_ulong __unused1; abi_ulong __unused2; }; struct target_msqid64_ds { struct target_ipc64_perm msg_perm; unsigned int msg_stime; /* last msgsnd time */ unsigned int msg_rtime; /* last msgrcv time */ unsigned int msg_ctime; /* last change time */ abi_ulong msg_cbytes; /* current number of bytes on queue */ abi_ulong msg_qnum; /* number of messages in queue */ abi_ulong msg_qbytes; /* max number of bytes on queue */ unsigned int msg_lspid; /* pid of last msgsnd */ unsigned int msg_lrpid; /* last receive pid */ abi_ulong __unused4; abi_ulong __unused5; }; #define UNAME_MACHINE "x86_64" #define UNAME_MINIMUM_RELEASE "2.6.32" #define TARGET_ARCH_SET_GS 0x1001 #define TARGET_ARCH_SET_FS 0x1002 #define TARGET_ARCH_GET_FS 0x1003 #define TARGET_ARCH_GET_GS 0x1004 #define TARGET_MINSIGSTKSZ 2048 #define TARGET_MLOCKALL_MCL_CURRENT 1 #define TARGET_MLOCKALL_MCL_FUTURE 2