Coder Social home page Coder Social logo

ashikkalavadiya / docker-alpine-apache Goto Github PK

View Code? Open in Web Editor NEW

This project forked from nimmis/docker-alpine-apache

0.0 1.0 0.0 156 KB

This is a micro docker container based on Alpine and Apache2

HTML 65.55% CSS 11.97% JavaScript 5.81% Shell 16.67%

docker-alpine-apache's Introduction

Alpine microcontainer with Apache2

This is a micro docker container based on Alpine OS and Apache version 2.

There images are build on nimmis/alpine-micro which are a modified version of Alpine OS with a working init process, cron, logrotate and syslog. All services are started by runit daemon, for more information about how it works and setup of new services please visit https://hub.docker.com/r/nimmis/alpine-micro/ for more information.

The container also have a backup system with cron schedule, number of copies to save etc, for information about the backup system please visit the README.md for the backupsystem

starting the container as a daemon

docker run -d --name apache nimmis/alpine-apache

This will start the container with apache process running, to access the container use

docker exec -ti apache /bin/sh

Static web folder

The images exposes a volume at /web. The structure is

Directory Function
/web/html web root
/web/cgi-bin cgi bin folder
/web/config apache config directory
/web/logs apache log directory
/web/internal internal pages, error pages etc

To use this start the container with

docker run -d --name -apache -v /path/to/web:/web nimmis/alpine-apache

if the folders are missing they will be created each time the container is started.

Accessing apache from outside the container

To access the webserver from external you can the -P/-p paramter, with -P the ports 80 and 443 is automaticly exposed and assign a random port.

or use the -p command to assign other ports, the syntax is

-p <external port on host>:<local port in container>

so to access the apache server port 80 on port 8080 you should use the command

docker run -d --name apache -p 8080:80 nimmis/alpine-apache

or assigning 80->80 and 443->443 use

docker run -d --name apache -p 80:80 -p 443:443 nimmis/alpine-apache

Successsful setup

If everything worked and you where able to expose the correct port and type the correct adress in a webbrowser the following page should appear.

screenshot

docker-alpine-apache's People

Contributors

nimmis avatar

Watchers

Ashik Patel avatar

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.