Coder Social home page Coder Social logo

inas's Introduction

🤵‍inas

A dockerized developer environment for working with legacy PHP projects. Includes Apache2, PHP 5.6, PHP 7.1 and MySQL 5.7.

System requirements

  • PHP 8.2
  • Docker (or compatible software like OrbStack)

You also need to be able to resolve .test domains to 127.0.0.1.

  • If you have Laravel Valet or Herd installed, you already got this done. Run sudo brew services start dnsmasq after stopping Valet or Herd.
  • Or you can manually add your sites to your /etc/hosts file

Installation

Automatic install

sh <(curl https://raw.githubusercontent.com/nxu/inas/main/install.sh)

This downloads the inas PHAR file to /usr/local/bin/inas, gives it executable permissions and runs inas install.

You'll be able to run inas from anywhere.

Manual install

Download the latest inas binary from the releases and run inas install.

Usage

Add a site to Inas

Go to a site containing your PHP project and run

cd ~/code/myproject

inas add <phpver>

# inas add 5.6
# inas add 7.1

This will add the site to Inas. The site will be available at http://myproject.test where myproject is the name of the folder you added.

Start inas

inas start

Stop inas

inas stop

Remove site from inas

cd ~/code/myproject

inas remove

Accessing MySQL

Your sites will be able to access the MySQL5.7 server at the host mysql:

DB_HOST=mysql
DB_PORT=3306
DB_USERNAME=root
DB_PASSWORD=root
  • You can access this server from your host at 127.0.0.1:3356.
  • The database will be persisted in ~/.config/inas/volumes/mysql.

Logs

You can find the server logs in:

  • ~/.config/inas/volumes/apache_logs for apache logs
  • ~/.config/inas/volumes/nginx_logs for nginx logs

inas's People

Contributors

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