Skip to content

Instantly share code, notes, and snippets.

View amir5121's full-sized avatar
🌍

Amir Heshmati amir5121

🌍
View GitHub Profile
@amir5121
amir5121 / Dockerfile
Created September 4, 2021 06:59
Dockerfile for wordpress with ioncube installation
# taken from https://github.com/sebastian13/docker-wordpress-ioncube/blob/master/7.1-apache/Dockerfile
# with small modification so you don't need to pass version as argument so now ioncube install the correct
# version by only changing the php version
FROM dockerhub.ir/wordpress:5.6-php7.3-fpm
ADD https://downloads.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz /tmp/
RUN PHP_VER=$(php -v | head -n 1 | awk '{print $2}' | awk -F '.' '{print $1"."$2}') && \
tar xvzfC /tmp/ioncube_loaders_lin_x86-64.tar.gz /tmp/ && \
php_ext_dir="$(php -i | grep extension_dir | head -n1 | awk '{print $3}')" && \
@amir5121
amir5121 / setup_docker.sh
Last active May 15, 2021 05:15
Docker setup on Ubuntu behind proxy when docker is banned (In Iran for example)
## this bit is from https://docs.docker.com/engine/install/ubuntu/
# first make sure you don't have it installed
echo "removing previously installed docker instances"
sudo apt-get remove docker docker-engine docker.io containerd runc
echo "installing certificated and repository"
sudo apt-get update
sudo apt-get install apt-transport-https ca-certificates curl gnupg lsb-release -y