GithubHelp home page GithubHelp logo

h3-workshop's Introduction

H3 Fullstack Workshop

This project is the workshop project for the H3 fullstack lessons at HETIC.

In this project, we'll build a Notion pages downloader that enables saving pages to a custom database for later use, and commenting those pages.

This project is a web application, and uses Symfony and React.

Install the project

This project comes ready with a docker-compose environment that can be used for development purposes. This environment has three containers :

  • workshop-nginx : An nginx container that serves the content, it listens on port 8080. Your machine's 8080 port is forwarded to the container's 8080 port.
  • workshop-php : A php container that runs a php development image with basic extensions enabled, as well as the symfony cli and composer cli installed
  • workshop-mariadb : A mariadb container that listens on port 3307. Your machine's 3307 port is forwarded to the container's 3307 port.

To start the environment, you need to run the following commands :

# Copy the versionned .env.dist file to .env
cp .env.dist .env
# Edit the .env file to add the correct variables values
vim .env
# Now start the stack
docker-compose up -d

# At all times you can check the state of the containers by running
docker ps
# or
docker-compose ps

Using Symfony commands in the php container

To run Symfony specific commands, you'll need to be in the workshop-php container. You can achieve this like this

docker exec -it workshop-php $COMMAND
# For example, to use the symfony cache:clear command
docker exec -it workshop-php php bin/console cache:clear

To make this easier you can add this alias to your zsh profile

alias sf="docker exec -it workshop-php"

# You can use the alias this way
sf php bin/console cache:clear

Using mariabd cli in the mariadb container

You have several ways to connect to the mariadb container. You can either directly use the mysql-client cli using this command :

docker exec -it workshop-mysql mysql -u workshop -p

Or you can configure your GUI mysql editor to connect to 127.0.0.1:3307 (if you're using Sequel Pro or TablePlus for example). This will let you acces the database without having to code.

You're now ready to work with this stack !

Navigating the git tree

This project has two branches :

  • main : the main branch of the project
  • develop : the development branch of the project

The main branch has purposefully not been committed in so that you can start with an empty repository and navigate the git tree.

h3-workshop's People

Contributors

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