-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdeploymnet.yaml
46 lines (46 loc) · 1.23 KB
/
deploymnet.yaml
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginxlamp
namespace: development
spec:
selector:
matchLabels:
app: lamp
replicas: 1
template:
metadata:
labels:
app: lamp
spec:
initContainers:
- name: init
image: ubuntu # alpine:3.5
command:
- /bin/bash
- -c
- |
cd /app
apt-get update && apt-get install -y wget
wget https://www.1c-bitrix.ru/download/small_business_encode.tar.gz
tar -xf small_business_encode.tar.gz
sed -i '5i php_value short_open_tag 1' .htaccess
chmod -R 0777 .
sed -i 's/#php_value display_errors 1/php_value display_errors 1/' .htaccess
sed -i '5i php_value opcache.revalidate_freq 0' .htaccess
sed -i 's/#php_flag default_charset UTF-8/php_flag default_charset UTF-8/' .htaccess
# apk --update add git && rm -rf /var/cache/apk/*
volumeMounts:
- name: app
mountPath: /app
containers:
- name: lamp
image: essch/su22:0.12
ports:
- containerPort: 80
volumeMounts:
- name: app
mountPath: /app
volumes:
- name: app
emptyDir: {}