GithubHelp home page GithubHelp logo

Provide a Dockerfile about openvpn-admin HOT 3 OPEN

chocobozzz avatar chocobozzz commented on May 25, 2024 1
Provide a Dockerfile

from openvpn-admin.

Comments (3)

seppi91 avatar seppi91 commented on May 25, 2024

I've made a first attempt to accomplish this by writing my first dockerfile. I installed all the prerequisites, created some required directories and executed the npm install procedure. I skipped the mysql installation as it looks to me more lightweight to build therefore a separate mysql container and connect them by "docker --link" command.

Actually I stuck at the install.sh script which is only written for a local mysql installation and accepts no parameters for host, port and root_password.

FROM eboraas/apache-php

MAINTAINER Sebastian Mittnacht [email protected]

# Install prerequisites
RUN apt-get -y update && apt-get install -y openvpn mysql-client nodejs unzip \
    git wget sed npm curl

# Cloneing and switching directory
RUN mkdir -p ~/.ssh && \
    ssh-keyscan github.com >> ~/.ssh/known_hosts &&\
    mkdir -p /usr/src/OpenVPN-Admin && \
    git clone https://github.com/seppi91/OpenVPN-Admin.git /usr/src/OpenVPN-Admin && \
    mkdir -p /opt/OpenVPN-Admin

WORKDIR /usr/src/OpenVPN-Admin
RUN git checkout docker

# Install nodejs server
RUN npm install -g bower && \
    ln -s /usr/bin/nodejs /usr/bin/node

VOLUME ["/etc/openvpn"]

EXPOSE 1194/udp 443/tcp

ARG MYSQL_PASS
ARG WEB_USER=www-data
ARG WEB_GROUP=www-data
ENV WEB_BASE=/opt/OpenVPN-Admin

CMD ["/bin/sh", "-c", "./install.sh $WEB_USER $WEB_GROUP $WEB_BASE $MYSQL_PASS"]

from openvpn-admin.

Chocobozzz avatar Chocobozzz commented on May 25, 2024

I recommend you to install mysql in the container, try to make things work and then put it outside and link them with docker compose for example :)

Maybe https://github.com/kylemanna/docker-openvpn could help you?

from openvpn-admin.

InAnimaTe avatar InAnimaTe commented on May 25, 2024

Actually, don't do that (include mysql inside). You're really going to need to do everything the install script does in the Dockerfile. The idea is that when they go to launch this, it starts and is ready to go (serving etc..)

from openvpn-admin.

Related Issues (20)

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.