-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix supervisor -c config path, Dockerfile fix
- Loading branch information
vsilent
committed
Jun 13, 2019
1 parent
c79c33c
commit a488758
Showing
20 changed files
with
4,582 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
# Created by .ignore support plugin (hsz.mobi) | ||
# Ide # | ||
################## | ||
.classpath | ||
.project | ||
.settings | ||
.idea | ||
.metadata | ||
*.iml | ||
*.ipr | ||
################## | ||
|
||
# Compiled source # | ||
################### | ||
*.com | ||
*.class | ||
*.dll | ||
*.exe | ||
*.o | ||
*.so | ||
|
||
# Packages # | ||
############ | ||
# it's better to unpack these files and commit the raw source | ||
# git has its own built in compression methods | ||
*.7z | ||
*.dmg | ||
*.gz | ||
*.iso | ||
*.jar | ||
*.rar | ||
*.tar | ||
*.zip | ||
|
||
# Logs and databases # | ||
###################### | ||
*.log | ||
*.sql | ||
*.sqlite | ||
|
||
# OS generated files # | ||
###################### | ||
.DS_Store | ||
.DS_Store? | ||
._* | ||
.Spotlight-V100 | ||
.Trashes | ||
ehthumbs.db | ||
Thumbs.db | ||
|
||
# WWW folder # | ||
www/ | ||
|
||
# python | ||
__pycache__ |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
REGISTRY= | ||
DOMAIN=localdomain | ||
|
||
# SMTP docker image | ||
SMTP_IMAGE={{SMTP_IMAGE}} | ||
EMAIl_ADMIN=admin@localhost | ||
EMAIL_USE_TLS=False | ||
EMAIL_HOST=smtp.gmail.com | ||
EMAIL_PORT=587 | ||
EMAIL_HOST_USER=[email protected] | ||
EMAIL_HOST_PASSWORD=pass | ||
DEFAULT_FROM_EMAIL=[email protected] | ||
|
||
MYSQL_DATABASE=osticket | ||
MYSQ_USER=osticket | ||
MYSQL_ROOT_PASSWORD=osticketroot | ||
|
||
DEBUG=True |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
FROM ubuntu:18.04 | ||
|
||
LABEL maintainer="[email protected]" | ||
ENV APP_VERSION 1.12 | ||
|
||
RUN apt-get update -y -qq ; apt-get install --no-install-recommends -y -qq supervisor software-properties-common; \ | ||
LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php -y; apt-get update -y -qq; \ | ||
apt-get install -y -qq cron curl net-tools \ | ||
php7.2 php7.2-fpm php7.2-mysql php7.2-cli php7.2-cgi php7.2-gd php7.2-zip php7.2-xml php7.2-curl \ | ||
&& apt-get clean; apt-get autoclean; apt-get autoremove -y -qq && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* | ||
|
||
RUN groupadd -r -g 2000 osticket; useradd -r -u 2000 -g 2000 -m -c "app account" -d /home/osticket -s /bin/bash osticket | ||
RUN curl -L -o /usr/src/app.tar.gz https://github.com/osTicket/osTicket/archive/v${APP_VERSION}.tar.gz | ||
WORKDIR /home/osticket | ||
RUN tar -xf /usr/src/app.tar.gz && mv osTicket-${APP_VERSION} app | ||
RUN chown -R osticket:osticket app | ||
ADD ./configs/php/fpm/php.ini /etc/php/7.2/fpm/php.ini | ||
ADD ./configs/php/fpm/www.conf /etc/php/7.2/fpm/pool.d/www.conf | ||
ADD ./configs/supervisord/osticket.conf /etc/supervisor/conf.d/osticket.conf | ||
RUN mkdir /run/php && chown -R osticket:osticket /run/php | ||
|
||
EXPOSE 9000 | ||
CMD ["/usr/bin/supervisord", "-c", "/etc/supervisor/conf.d/osticket.conf"] |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
[supervisord] | ||
nodaemon = true | ||
loglevel = INFO | ||
logfile=/dev/null | ||
logfile_maxbytes=0 | ||
pidfile=/var/run/supervisord.pid ; (supervisord pidfile;default supervisord.pid) | ||
|
||
[unix_http_server] | ||
file = /tmp/supervisor.sock | ||
chmod = 0700 | ||
username = dummy | ||
password = dummy | ||
|
||
[supervisorctl] | ||
username = dummy | ||
password = dummy | ||
|
||
[program:php-fpm] | ||
command=/usr/sbin/php-fpm7.2 -F | ||
stopasgroup=true | ||
stopsignal=TERM | ||
autostart=true | ||
stdout_logfile=/dev/fd/1 | ||
stdout_logfile_maxbytes=0 | ||
redirect_stderr=true | ||
|
||
[program:cron] | ||
command=/usr/sbin/cron -f | ||
stopsignal=TERM | ||
stopasgroup=true | ||
autostart=true | ||
stdout_logfile=/dev/fd/1 | ||
stdout_logfile_maxbytes=0 | ||
redirect_stderr=true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
server { | ||
listen 80; | ||
server_name _; | ||
index index.php index.html; | ||
root /usr/share/nginx/html; | ||
|
||
# Add stdout/stderr logging | ||
access_log /proc/self/fd/1; | ||
error_log /proc/self/fd/2; | ||
|
||
location ~ \.php$ { | ||
try_files $uri /dev/null =404; | ||
fastcgi_pass osticket:9000; | ||
fastcgi_index index.php; | ||
include fastcgi_params; | ||
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; | ||
} | ||
|
||
location / { | ||
try_files $uri $uri/ /index.php?$query_string; | ||
} | ||
|
||
# deny access to . files, for security | ||
location ~ /\. { | ||
access_log off; | ||
log_not_found off; | ||
deny all; | ||
} | ||
|
||
gzip_types text/css text/less text/plain text/xml application/xml application/json application/javascript; | ||
gzip_static on; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
user www-data; | ||
worker_processes auto; | ||
worker_rlimit_nofile 200000; | ||
|
||
pid /var/run/nginx.pid; | ||
|
||
events { | ||
worker_connections 10000; | ||
use epoll; | ||
multi_accept on; | ||
} | ||
|
||
http { | ||
include /etc/nginx/mime.types; | ||
default_type application/octet-stream; | ||
keepalive_requests 10000; | ||
|
||
sendfile on; | ||
sendfile_max_chunk 512k; | ||
tcp_nopush on; | ||
tcp_nodelay on; | ||
|
||
large_client_header_buffers 8 64k; | ||
output_buffers 8 32k; | ||
postpone_output 1460; | ||
|
||
# 502 error fix | ||
proxy_connect_timeout 120s; | ||
proxy_read_timeout 120s; | ||
proxy_busy_buffers_size 16k; | ||
proxy_temp_file_write_size 64k; | ||
client_header_timeout 3m; | ||
client_body_timeout 3m; | ||
send_timeout 3m; | ||
|
||
#error_log /var/log/nginx.error_log warn; | ||
# Add stdout/stderr logging | ||
access_log /proc/self/fd/1; | ||
error_log /proc/self/fd/2; | ||
|
||
log_format main '$remote_addr - $remote_user [$time_local] ' | ||
'"$request" $status $bytes_sent ' | ||
'"$http_referer" "$http_user_agent" ' | ||
'"$gzip_ratio"'; | ||
|
||
log_format download '$remote_addr - $remote_user [$time_local] ' | ||
'"$request" $status $bytes_sent ' | ||
'"$http_referer" "$http_user_agent" ' | ||
'"$http_range" "$sent_http_content_range"'; | ||
|
||
map $status $loggable { | ||
~^[23] 0; | ||
default 1; | ||
} | ||
include /etc/nginx/conf.d/*.conf; | ||
} |
Oops, something went wrong.