Logo Ricky
  • 首頁
  • 關於
  • 更多的
    技能 經歷 學歷 專案
  • 文章
  • 筆記
  • 活動
  • Transform
  • Chinese
    English Chinese
  • Dark Theme
    Light Theme Dark Theme System Theme
Logo Inverted Logo
  • 標籤
  • A10
  • ACME
  • AD
  • AES
  • AI
  • Aliyun
  • Ansible
  • APP
  • Application Delivery Controller
  • Arceus
  • Argo CD
  • ASCII
  • Authentication
  • Authorization
  • AWS
  • BASH
  • Bayonet
  • Benchmark
  • BGP
  • BIRD
  • Board Game
  • Browser
  • Byte
  • Cache
  • CDN
  • Channel
  • Chart
  • Checklist
  • Chrome
  • Chrome OS
  • Chrony
  • CI
  • Cilium
  • Cisco
  • Cloud-Native
  • Cloudflare
  • Cluster
  • Command Line
  • Completion
  • Config
  • Container
  • CPU
  • CURL
  • Data
  • Database
  • Debug
  • Dehydrated
  • Design
  • DevSecOps
  • Diagrams
  • Dmg
  • DNS
  • DNS-01
  • Docker
  • EFF
  • ElasticSearch
  • ELK
  • Emoji
  • EMQX
  • Encode
  • Encrypt
  • ESXi
  • Extension
  • Firewall
  • Fortigate
  • Fortinet
  • FortiOS
  • Game
  • GeoIP
  • GIN
  • Git
  • GitBook
  • Github
  • Gitlab
  • GitOps
  • Gluetun
  • Go
  • Go-Mysql-Elasticsearch
  • Golang
  • Google
  • GPG
  • GraphQL
  • HA
  • HAProxy
  • Hash
  • HomeLab
  • Htop
  • HTTP
  • Infra
  • Infrastructure
  • Input Method
  • Interview
  • Introduction
  • IPhone
  • Iptables
  • Iso
  • Issue
  • ITerm2
  • Jenkins
  • Jsoniter
  • Juniper
  • JWT
  • Kibana
  • Kubernetes
  • LDAP
  • Leetcode
  • Lightweight
  • Linkerd
  • Linux
  • LLM
  • Log
  • Lua
  • Lullaby
  • LVM
  • Machinelearning
  • MacOS
  • Markdown
  • Mattermost
  • Mermaid
  • MinIO
  • Module
  • MQTT
  • MSS
  • MTU
  • Music
  • MyDumper
  • MySQL
  • NAS
  • Netcat
  • Network
  • Nftables
  • Nginx
  • OAuth
  • OIDC
  • Ollama
  • OpenResty
  • Parquet
  • Percona
  • Pinyin
  • Pip
  • Plugin
  • Pokemon
  • PowerDNS
  • PowerShell
  • Pprof
  • Principle
  • Prometheus
  • Protobuf
  • Proxy
  • Push
  • Python
  • QRCode
  • R
  • RAID
  • RDP
  • Redis
  • Regex
  • Ringtone
  • Route
  • Rust
  • S3
  • ScreenShot
  • Security
  • Selenium
  • Sentry
  • Service Mesh
  • SFTP
  • SHELL
  • Slides
  • Snow
  • Software
  • SonarQube
  • SQL
  • SSH
  • SSL
  • String
  • Switch
  • Sync
  • Synology
  • System
  • Tcpdump
  • Telegram
  • Terminal
  • Terraform
  • Test
  • Testing
  • Time
  • Timeout
  • TLS
  • Tor
  • Trace
  • Traefik
  • Travel
  • Tunnel
  • Typora
  • Ubuntu
  • URL
  • UserAgent
  • V2Ray
  • Vagrant
  • Video
  • Vim
  • Virtualization
  • Visualization
  • VNC
  • VPN
  • VSCode
  • WAF
  • Web
  • WebAssembly
  • Webp
  • Windows
  • WSL
  • YAML
  • Youtube
  • Zabbix
  • Zero Trust
  • Zim
  • ZSH
  • 台語
Hero Image
Docker Tips: Using Docker Config

Docker Tips: Using Docker Config FROM nginx:1.13.6 COPY nginx.conf /etc/nginx/nginx.conf Using the Docker CLI, we can create a config from this configuration file, we name this config proxy. $ docker config create proxy nginx.conf mdcfnxud53ve6jgcgjkhflg0s $ docker config inspect proxy [ { "ID": "x06uaozphg9kbnf8g4az4mucn", "Version": { "Index": 2723 }, "CreatedAt": "2017-11-21T07:49:09.553666064Z", "UpdatedAt": "2017-11-21T07:49:09.553666064Z", "Spec": { "Name": "proxy", "Labels": {}, "Data": "dXNlciB3d3ctZGF0YTsKd29y...ogIgICAgIH0KICAgIH0KfQo=" } } ] Use a Config $ docker network create --driver overlay front $ docker service create --name api --network front lucj/api $ docker service create --name proxy \ --network front \ --config src=proxy,target=/etc/nginx/nginx.conf \ --port 8000:8000 \ nginx:1.13.6 Service Update When the content of a configuration needs to be modified, it’s a common pattern to create a new config (using docker config create), and then to update the service order to remove the access to the previous config, and to add the access to the new one. The service commands are--config-rm and --config-add.

Monday, September 14, 2020 閱讀
Hero Image
How to deploy on remote Docker hosts with docker-compose

How to deploy on remote Docker hosts with docker-compose Manual deployment by copying project files, install docker-compose and running it $ scp -r hello-docker user@remotehost:/path/to/src $ ssh user@remotehost $ pip install docker-compose $ cd /path/to/src/hello-docker $ docker-compose up -d Using DOCKER_HOST environment variable to set up the target engine $ cd hello-docker $ DOCKER_HOST="ssh://user@remotehost" docker-compose up -d Using docker contexts $ docker context create remote ‐‐docker "host=ssh://user@remotemachine" remote Successfully created context "remote" $ docker context ls NAME DESCRIPTION DOCKER ENDPOINT KUBERNETES ENDPOINT ORCHESTRATOR default * Current DOCKER_HOST… unix:///var/run/docker.sock swarm remote ssh://user@remotemachine $ cd hello-docker $ docker-compose ‐‐context remote up -d

Wednesday, March 25, 2020 閱讀
  • ««
  • «
  • 1
  • 2
  • »
  • »»
導覽列
  • 關於
  • 技能
  • 經歷
  • 學歷
  • 專案
聯絡方式:
  • zeyanlin@outlook.com
  • linzeyan
  • Ricky
  • Ricky