Giter Site home page Giter Site logo

showrunner's People

Contributors

allcontributors[bot] avatar jontheniceguy avatar thelovebug avatar

Watchers

 avatar  avatar

showrunner's Issues

Rather than using Virtualbox images, it might be less resource hungry to use Docker instead.

I have a Proof Of Concept which works, but I need to refine it to make sure it's right.

POC based on:
https://github.com/bubenkoff/vagrant-docker-example
https://docs.docker.com/engine/examples/running_ssh_service/

Here's the new Vagrantfile

VAGRANTFILE_API_VERSION = "2"
Vagrant.require_version ">= 1.6.0"

Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
  config.vm.provider "docker" do |d|
    d.build_dir = "."
    d.has_ssh = true
  end
  config.vm.provision "shell", path: "./run_setup.sh"
  config.vm.provision "shell", run: "always", path: "./run_showmaker.sh"
end

Here's the Dockerfile

FROM ubuntu:14.04
MAINTAINER CCHits "[email protected]"
RUN apt-get update && apt-get install -y openssh-server lsb-release sudo

RUN mkdir -m 0755 -p /var/run/sshd

# Create and configure vagrant user
RUN useradd --create-home -s /bin/bash vagrant
RUN echo -n 'vagrant:vagrant' | chpasswd

# Configure SSH access
RUN mkdir -m 0700 -p /home/vagrant/.ssh && echo "ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEA6NF8iallvQVp22WDkTkyrtvp9eWW6A8YVr+kz4TjGYe7gHzIw+niNltGEFHzD8+v1I2YJ6oXevct1YeS0o9HZyN1Q9qgCgzUFtdOKLv6IedplqoPkcmF0aYet2PkEDo3MlTBckFXPITAMzF8dJSIFo9D8HfdOV0IAdx4O7PtixWKn5y2hMNG0zQPyUecp4pzC6kivAIhyfHilFR61RGL+GPXQ2MWZWFYbAGjyiYJnAmCP3NOTd0jMZEnDkbUvxhMmBYSdETk1rRgm+R4LOzFUGaHqHDLKLX+FIPKcF96hrucXzcWyLbIbEgE98OHlnVYCzRdK8jlqm8tehUc9c9WhQ== vagrant insecure public key" > /home/vagrant/.ssh/authorized_keys && chown -R vagrant:vagrant /home/vagrant/.ssh ; chmod 600 /home/vagrant/.ssh/*

# Enable passwordless sudo for the "vagrant" user
RUN mkdir -m 0755 -p /etc/sudoers.d && install -b -m 0440 /dev/null /etc/sudoers.d/vagrant && echo 'vagrant ALL=NOPASSWD:ALL' >> /etc/sudoers.d/vagrant

EXPOSE 22
CMD ["/usr/sbin/sshd","-D"]

I think the only other change that needs to be made is that the Docker container can't be "shutdown" using shutdown -h now. I think we need to let the showrunner finish, and then run vagrant halt.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.