Last active
February 10, 2020 11:26
-
-
Save gorshkov-leonid/7459e31cedaf3c0c83f5ac004c539dac to your computer and use it in GitHub Desktop.
This file contains hidden or 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
RUN yum install -y initscripts && \ | |
yum install -y sudo.x86_64 && \ | |
yum install -y openssh-server.x86_64 && yum clean all && \ | |
https://wiki.centos.org/HowTos/Network/SecuringSSH#head-2c570b3605b9f578c5b79301bfeb4a98bad9c9c4 | |
https://linux.die.net/man/8/sshd | |
http://help.ubuntu.ru/wiki/ssh |
This file contains hidden or 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
ls /etc/yum.repos.d/ #see all repos | |
yum-config-manager --disable CentOS-* #disable all repos starting from "Centos-" | |
yum-config-manager --nogpgcheck --add-repo url_to_my_repo | |
rpm --import url_to_gpg_to_that repo |
This file contains hidden or 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
yum -y update && \ | |
yum -y install make gcc perl pcre-devel zlib-devel && \ | |
curl https://www.openssl.org/source/openssl-1.1.1c.tar.gz --output openssl-1.1.1c.tar.gz && \ | |
tar xvf openssl-1.1.1c.tar.gz && \ | |
cd openssl-1.1.1c && \ | |
./config --prefix=/usr --openssldir=/etc/ssl --libdir=lib no-shared zlib-dynamic && \ | |
make && \ | |
make install |
This file contains hidden or 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
- ssh ${MY_SSH} "echo \"$(cat ca.cert)\" > /home/user/me/ca.cert" | |
- ssh ${MY_SSH} sudo docker run -d -p 8080:8080 -i -t --name ${NAME} ${ENV} -e MY_CERT="\"\$(cat /home/user/me/ca.cert)\"" imagename | |
# sault is quotas |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment