31 lines
600 B
C
31 lines
600 B
C
#ifndef JOB_H
|
|
#define JOB_H
|
|
|
|
#include "agent_ssl.h"
|
|
#include "../src/protocol.h"
|
|
|
|
enum pthread_state { WAIT, WORK };
|
|
enum job_slot_state { FREE, FULL };
|
|
|
|
struct job_args {
|
|
struct msg_t buf;
|
|
unsigned short slot;
|
|
SSL *ssl;
|
|
};
|
|
|
|
void* exec_unix(void *args);
|
|
void* install_pkg(void *args);
|
|
void* query_pkg(void *args);
|
|
void* delete_pkg(void *args);
|
|
void* list_pkgs(void *args);
|
|
void* update_pkg(void *args);
|
|
void* update_pkgs(void *args);
|
|
void* get_os(void *args);
|
|
void* get_kernel(void *args);
|
|
void* get_uptime(void *args);
|
|
void* get_memory(void *args);
|
|
|
|
#define MAX_AGENT_JOBS 10
|
|
|
|
#endif /* JOB_H */
|