- apiVersion: Which version of the Kubernetes API you’re using to create this object
- kind: What kind of object you want to create
- metadata: Data that helps uniquely identify the object, including a name string, UID, and optional namespace
- spec: What state you desire for the object
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
apiVersion: apps/v1 # for versions before 1.9.0 use apps/v1beta2 | |
kind: Deployment | |
metadata: | |
name: nginx-deployment | |
spec: | |
selector: | |
matchLabels: | |
app: nginx | |
replicas: 2 # tells deployment to run 2 pods matching the template | |
template: |
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
version: '3' | |
services: | |
drone-server: | |
container_name: drone-server | |
image: drone/drone:1.6 | |
volumes: | |
- ./drone_data:/var/lib/drone/ | |
- /var/run/docker.sock:/var/run/docker.sock | |
ports: |
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
FROM gliderlabs/alpine:3.3 | |
ENV FFMPEG_VERSION=4.0.5 | |
WORKDIR /tmp/ffmpeg | |
RUN apk add --update build-base curl file nasm tar bzip2 \ | |
zlib-dev openssl-dev yasm-dev lame-dev libogg-dev x264-dev libvpx-dev libvorbis-dev x265-dev freetype-dev libass-dev libwebp-dev rtmpdump-dev libtheora-dev opus-dev && \ | |
DIR=$(mktemp -d) && cd ${DIR} && \ | |
curl -s http://ffmpeg.org/releases/ffmpeg-${FFMPEG_VERSION}.tar.gz | tar zxvf - -C . && \ |
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
### I got the idea from here: | |
### https://stackoverflow.com/questions/39514293/docker-nginx-proxy-how-to-route-traffic-to-different-container-using-path-and-n | |
version: '3.8' | |
services: | |
nginx-proxy: | |
image: jwilder/nginx-proxy:alpine | |
ports: |
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
# For more information: https://laravel.com/docs/sail | |
version: '3' | |
services: | |
laravel.test: | |
container_name: sail-laravel | |
build: | |
context: ./vendor/laravel/sail/runtimes/7.4 | |
dockerfile: Dockerfile | |
args: | |
WWWGROUP: '${WWWGROUP}' |
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
version: '3.8' | |
services: | |
registry: | |
restart: always | |
image: registry:2.7.1 | |
container_name: registry | |
environment: | |
REGISTRY_AUTH_HTPASSWD_PATH: /auth/htpasswd | |
REGISTRY_AUTH_HTPASSWD_REALM: Registry Realm |
اینجا سعی کردم خلاصه مباحث مرتبط بین لینوکس و کانتینرها رو به واسطه تدریس در دوره آموزشی داکر گرینوب، گردآوری کنم.
جزییات دوره: https://evnd.co/l2PJx
- First, read this concept: https://fen.wikipedia.org/wiki/OS-level_virtualization
- Many people use container systems like Docker, but how do they work? https://bit.ly/3fLhb58
Nginx can be configured to route to a backend, based on the server's domain name, which is included in the SSL/TLS handshake (Server Name Indication, SNI).
This works for http upstream servers, but also for other protocols, that can be secured with TLS.
- at least nginx 1.15.9 to use variables in ssl_certificate and ssl_certificate_key.
- check
nginx -V
for the following:... TLS SNI support enabled
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
{ | |
"users": [ | |
{ | |
"id": 1, | |
"name": "Alice", | |
"age": 28, | |
"status": "active", | |
"books": [ | |
"Test", | |
"Good", |
OlderNewer