-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
454ad46
commit 0fd7e2b
Showing
21 changed files
with
181 additions
and
219 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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,27 @@ | ||
FROM nginx:stable-alpine AS base | ||
|
||
RUN printf "\ | ||
server {\n\ | ||
listen 80;\n\ | ||
index index.php index.html;\n\ | ||
error_log /var/log/nginx/error.log;\n\ | ||
access_log /var/log/nginx/access.log;\n\ | ||
root /var/www/html;\n\ | ||
location ~ \.php$ {\n\ | ||
try_files \$uri =404;\n\ | ||
fastcgi_split_path_info ^(.+\.php)(/.+)$;\n\ | ||
fastcgi_pass ogspy:9000;\n\ | ||
fastcgi_index index.php;\n\ | ||
include fastcgi_params;\n\ | ||
fastcgi_param SCRIPT_FILENAME \$document_root\$fastcgi_script_name;\n\ | ||
fastcgi_param PATH_INFO \$fastcgi_path_info;\n\ | ||
}\n\ | ||
location / {\n\ | ||
try_files \$uri \$uri/ /index.php?\$query_string;\n\ | ||
gzip_static on;\n\ | ||
}\n\ | ||
}\n" > /etc/nginx/conf.d/default.conf | ||
|
||
EXPOSE 80 | ||
|
||
CMD ["nginx", "-g", "daemon off;"] |
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 @@ | ||
FROM php:8.2-fpm-alpine3.19 AS build | ||
|
||
RUN apk --no-cache add php-session \ | ||
php-tokenizer \ | ||
php-xml \ | ||
php-ctype \ | ||
php-curl \ | ||
php-dom \ | ||
php-fileinfo \ | ||
php-mbstring \ | ||
php-openssl \ | ||
php-pdo \ | ||
php-pdo_mysql \ | ||
php-mysqli \ | ||
php-session \ | ||
php-tokenizer \ | ||
php-xml \ | ||
php-ctype \ | ||
php-xmlwriter \ | ||
php-simplexml \ | ||
git \ | ||
composer | ||
|
||
RUN docker-php-ext-install mysqli pdo_mysql | ||
RUN docker-php-ext-enable mysqli pdo_mysql | ||
|
||
# RUN apk --no-cache add --update nodejs npm | ||
|
||
RUN git clone -b develop https://github.com/ogsteam/ogspy /var/www/html | ||
RUN git clone -b master https://github.com/ogsteam/mod-autoupdate /var/www/html/mod/autoupdate | ||
RUN git clone -b master https://github.com/ogsteam/mod-xtense /var/www/html/mod/xtense | ||
RUN git clone -b master https://github.com/ogsteam/mod-production /var/www/html/mod/production | ||
RUN git clone -b master https://github.com/ogsteam/mod-tempsvols /var/www/html/mod/tempsvols | ||
RUN git clone -b master https://github.com/ogsteam/mod-bthof /var/www/html/mod/bthof | ||
|
||
COPY id.php /var/www/html/parameters/id.php | ||
COPY key.php /var/www/html/parameters/key.php | ||
|
||
WORKDIR /var/www/html | ||
|
||
RUN composer install | ||
# RUN npm install | ||
|
||
EXPOSE 9000 | ||
|
||
RUN printf "\ | ||
rm -Rf /var/www/html/install\n\ | ||
rm -Rf /var/www/html/.git\n\ | ||
chmod -R o+w /var/www/html/\n\ | ||
chown -R root:root /var/www/html/\n\ | ||
php-fpm\n\ | ||
" > /start.sh | ||
|
||
RUN chmod +x "/start.sh" | ||
|
||
ENTRYPOINT "/start.sh" |
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 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,8 @@ | ||
-- create the databases | ||
CREATE DATABASE IF NOT EXISTS ogspy; | ||
|
||
-- create the users for each database | ||
CREATE USER 'admin'@'%' IDENTIFIED BY 'ogsteam'; | ||
GRANT CREATE, ALTER, INDEX, LOCK TABLES, REFERENCES, UPDATE, DELETE, DROP, SELECT, INSERT ON `ogspy`.* TO 'admin'@'%'; | ||
|
||
FLUSH PRIVILEGES; |
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,22 @@ | ||
server { | ||
listen 80; | ||
server_name localhost; | ||
|
||
root /var/www/html; | ||
index index.php index.html; | ||
|
||
location / { | ||
try_files $uri $uri/ /index.php?_share=; | ||
} | ||
|
||
location ~ \.php$ { | ||
try_files $uri =404; | ||
fastcgi_pass php8-fpm:9000; | ||
fastcgi_param SCRIPT_FILENAME $request_filename; | ||
include fastcgi_params; | ||
} | ||
|
||
location ~ /\.ht { | ||
deny all; | ||
} | ||
} |
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,65 @@ | ||
name: my-ogspy | ||
|
||
networks: | ||
ogspy-network: | ||
driver: bridge | ||
|
||
volumes: | ||
ogspy-db: | ||
driver: local | ||
ogspy-app: | ||
driver: local | ||
|
||
services: | ||
db: | ||
image: mariadb | ||
expose: | ||
- 3306 | ||
networks: | ||
- ogspy-network | ||
environment: | ||
MYSQL_ROOT_PASSWORD: password | ||
MYSQL_USER: demo | ||
MYSQL_PASSWORD: ogsteam | ||
volumes: | ||
- ogspy-db:/var/lib/mysql | ||
- ./db:/docker-entrypoint-initdb.d | ||
restart: always | ||
|
||
ogspy: | ||
build: | ||
context: . | ||
dockerfile: Dockerfile.ogspy | ||
networks: | ||
- ogspy-network | ||
volumes: | ||
- ogspy-app:/var/www/html | ||
- ./parameters:/var/www/html/parameters | ||
restart: always | ||
depends_on: | ||
- db | ||
|
||
nginx: | ||
build: | ||
context: . | ||
dockerfile: Dockerfile.nginx | ||
volumes: | ||
- ogspy-app:/var/www/html | ||
ports: | ||
- "16005:80" | ||
networks: | ||
- ogspy-network | ||
|
||
|
||
|
||
phpmyadmin: | ||
image: phpmyadmin | ||
ports: | ||
- "16006:80" | ||
environment: | ||
- PMA_HOST=db | ||
- PMA_PORT=3306 | ||
- UPLOAD_LIMIT=50000000 | ||
networks: | ||
- ogspy-network | ||
restart: always |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Ykaj9H5dTPV |
Oops, something went wrong.