vi /etc/environment
add these lines...
LANG=en_US.utf-8
LC_ALL=en_US.utf-8
Alternatively,
#!/bin/bash | |
# Before start, please check that sysctl net.ipv4.ip_forward is set to 1. | |
# Install yum packages | |
yum install -y vim curl net-tools bash-completion yum-utils lsof | |
# Install Docker latest. yum-utils package is required (which provides the yum-config-manager | |
# utility) in order to set up the docker stable repository. After install, we need to define | |
# docker network as insecure registry to prevent failure during cluster creation. |
vi /etc/environment
add these lines...
LANG=en_US.utf-8
LC_ALL=en_US.utf-8
Alternatively,
/!\ Be very carrefull in your setup : any misconfiguration make all the git config to fail silently ! Go trought this guide step by step and it should be fine 😉
~/.ssh/config
, set each ssh key for each repository as in this exemple:# -*- encoding: utf-8 -*- | |
# requires a recent enough python with idna support in socket | |
# pyopenssl, cryptography and idna | |
from OpenSSL import SSL | |
from cryptography import x509 | |
from cryptography.x509.oid import NameOID | |
import idna | |
from socket import socket |
# Backup | |
docker exec CONTAINER /usr/bin/mysqldump -u root -pPASSWORD DATABASE > backup.sql | |
docker exec CONTAINER /usr/bin/mysqldump -u root -pPASSWORD DATABASE | gzip > backup.sql.gz | |
docker exec CONTAINER /usr/bin/mysqldump -u root -pPASSWORD DATABASE | bzip2 > backup.sql.bz2 | |
# Restore | |
cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root -pPASSWORD DATABASE | |
gunzip < backup.sql.gz | docker exec -i CONTAINER /usr/bin/mysql -u root -pPASSWORD DATABASE | |
bunzip2 < backup.sql.bz2 | docker exec -i CONTAINER /usr/bin/mysql -u root -pPASSWORD DATABASE |
Here are the simple steps needed to create a deployment from your local GIT repository to a server based on this in-depth tutorial.
You are developing in a working-copy on your local machine, lets say on the master branch. Most of the time, people would push code to a remote server like github.com or gitlab.com and pull or export it to a production server. Or you use a service like deepl.io to act upon a Web-Hook that's triggered that service.
# Backup | |
docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > backup.sql | |
# Restore | |
cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE | |
@echo off | |
set dbUser=root | |
set dbPassword=password | |
set backupDir="F:\AdityaSatrioNugroho\testbackupDb-bat\" | |
set mysqldump="C:\xampp\mysql\bin\mysqldump.exe" | |
set mysqlDataDir="C:\xampp\mysql\data" | |
set zip="C:\Program Files\7-Zip\7z.exe" | |
:: get date |