Skip to main content

Posts

Showing posts from 2017
How to install Salt-Master with Salt-API in Docker Container In this guide, we will create a docker image with salt-master and salt-api installed on it. later we will use the same image to create the container. Clone the repo: git clone https://github.com/yogeshprasad/salt-examples.git Change the dir: cd /root/salt-examples/build-salt-master-api Build the docker image: docker build -t "salt-server-img" . Create the container: docker run -ti --name="my-salt-server" salt-server-img bash Test the api: curl -k https://172.17.0.2:8553/login -H "Accept: application/x-yaml" -d username='admin' -d password='password' -d eauth='pam 172.17.0.2 : It is a container private IP.
How to assign static public IP to the docker container   In this post, we will create a docker container and configure the static public IP so it will be reachable from outside. Here we will use the Linux  MAC VLANs and Virtual Ethernets. Prerequisites:     Ubuntu host up and running. Public IP should be configured. Docker should be installed. Skip to end of metadata Go to start of metadat PULL UBUNTU DOCKER IMAGE $  docker pull    ubuntu:14.04.5 It will download the Ubuntu docker image. Create a container $  docker run -ti --name container-1    --net=none --privileged=true ubuntu:14.04.5 bash This will create a docker container, now we will configure the static public ip to the container. ASSIGNING AN IP FOR A CONTAINER Here I am assuming that host machine is having interface "eth0" with public IP configured.  Name of the container is container-1.  The below steps needs to be performed on the docker host. Create a vir
Running Salt Minion In Docker Container From Scratch  In this post, we will install salt minion in docker container and configure the public IP so it will be reachable from outside. Prerequisites:     Ubuntu host up and running. Public IP should be configured. Docker should be installed. Skip to end of metadata Go to start of metadat PULL UBUNTU DOCKER IMAGE $  docker pull    ubuntu:14.04.5 It will download the Ubuntu docker image. Create a container for salt minion $  docker run -ti --name salt-minion-agent    --net=none --privileged=true ubuntu:14.04.5 bash This will create a container, we will use the same container to install salt minion. Now configure the network for this container. ASSIGNING AN IP FOR A CONTAINER Here I am assuming that host machine is having interface "eth0" with public IP configured.  Name of the container is salt-minion-agent.  The below steps needs to be performed on the docker host. Create a
Running Salt Master In Docker Container From Scratch  In this post, we will install salt master in docker container and configure the public IP so it will be reachable from outside. Prerequisites:     Ubuntu host up and running. Public IP should be configured. Docker should be installed. Skip to end of metadata Go to start of metadat Pull Ubuntu docker image $  docker pull   ubuntu:14.04.5 It will download the Ubuntu docker image. Create a container for salt master $  docker run -ti --name salt-master-server   --net=none --privileged=true ubuntu:14.04.5 bash This will create a container, we will use the same container to install salt master. Now configure the network for this container. Assigning an IP for a container Here I am assuming that host machine is having interface "eth0" with public IP configured.  Name of the container is salt-master-server.  The below steps needs to be performed on the docker host. Cre
How To Run Salt-Minion In Docker Container In this post we will use a Ubuntu based docker image in which I have already installed the salt-minion and  uploaded it into docker hub. Now if you are looking for installing the salt-minion in docker container from scratch then check out my other guide .    Here I am assuming that you are having Ubuntu host up and running with public IP configured on it. Skip to end of metadata Go to start of metadata Pull the docker image $ docker pull yogeshprasadkurmi/ubuntu-salt-minion This is a Ubuntu 14.04.5 based image with salt-minion installed on it. Salt-minion will be up and running if you create the container using this images. Create salt minion agent $ docker run -ti --name salt-minion-agent  --net=none --privileged=true yogeshprasadkurmi/ubuntu-salt-minion bash This will create a container with salt-minion installed on it. Assigning an IP for a container Here I am assuming that host machine is having int
How To Run Salt-Master In Docker Container In this post we will use a Ubuntu based docker image in which I have already installed the salt-master and  uploaded it into docker hub. If you are looking for installing the salt-master in docker container from scratch then check out  this guide . Here I am assuming that you are having Ubuntu host up and running with public IP configured on it. Skip to end of metadata Go to start of metadata Pull the docker image $ docker pull yogeshprasadkurmi/ubuntu-salt-master This is a Ubuntu 14.04.5 based image with salt-master installed on it. Salt-master will be up and running if you create the container using this images. Create Salt-master Server $ docker run -ti --name salt-master-server  --net=none --privileged=true yogeshprasadkurmi/ubuntu-salt-master bash This will create a container with salt-master installed on it. Assigning an IP for a container Here I am assuming that host machine is having interface &q
Add Virtual Link - Ubuntu 14.04 Here I am assuming that your Ubuntu machine is up and running and having a physical interface eth0. Add Virtual Link $ ip link add name veth1 link eth0 type macvlan mode bridge It will add the virtual interface veth1 without any Ip address . Add the ip address To add the ip address to newly created virtual link run below command Note: Here I am assuming that you are having DHCP server configured, If not you can manually assign the static IP address to veth1. $ dhclient -v veth1 This command will assign the random IP address to veth1