Code Monkey home page Code Monkey logo

rpm's Introduction

RPM build practice

The project consists of two parts:

  1. Compile and run nginx inside a vagrant machine and then create a repo of rpm packages based on nginx
  2. Create custom nginx docker image and push it into the Docker Cloud

Compile nginx inside Vagrant

  1. vagrant should be installed on your system
$ vagrant -v
Vagrant 2.2.5
  1. Clone this repository
$ git clone https://github.com/ligain/rpm.git  
  1. Go to project folder
$ cd rpm/
  1. Run vagrant
$ vagrant up

Build custom docker image with nginx

  1. docker should be installed on your system
$ docker --version
Docker version 17.05.0-ce, build 89658be
  1. Clone this repository
$ git clone https://github.com/ligain/rpm.git  
  1. Go to project folder
$ cd rpm/
  1. Build an image
$ docker build . -t custom-nginx:1.14.1
  1. Run container
$ docker run --name cust-nginx -p 8080:80 -d custom-nginx:1.14.1
  1. Test nginx welcome page on the host machine
$ curl localhost:8080
<!DOCTYPE html>
<html>
<head>
<title>Welcome to nginx!</title>
<style>
    body {
        width: 35em;
        margin: 0 auto;
        font-family: Tahoma, Verdana, Arial, sans-serif;
    }
</style>
</head>
<body>
<h1>Welcome to nginx!</h1>
<p>If you see this page, the nginx web server is successfully installed and
working. Further configuration is required.</p>

<p>For online documentation and support please refer to
<a href="http://nginx.org/">nginx.org</a>.<br/>
Commercial support is available at
<a href="http://nginx.com/">nginx.com</a>.</p>

<p><em>Thank you for using nginx.</em></p>
</body>
</html>
  1. Also you can pull this image from Docker Cloud
$ docker pull linder/custom-nginx

Project Goals

The code is written for educational purposes.

rpm's People

Contributors

ligain avatar

Watchers

 avatar  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.