Code Monkey home page Code Monkey logo

index-dev-env's Introduction

index-dev-env

Local development environment for CreativeCommons.org (product name: index).

Overview

This repository has the configuration required to run the CreativeCommons.org website in a local Docker development environment.

The CreativeCommons.org website is comprised of five components that are split into two categories:

  • dynamic component:
    • WordPress (Vocabulary Theme)
  • static components:
    • Chooser
    • FAQ
    • Legal Tools (licenses and public domain)
    • Platform Toolkit

Component repositories

Path label Path Component name Component repositories
Chooser /choose Chooser chooser
FAQ /faq FAQ faq
Licenses /licenses CC Legal Tools cc-legal-tools-app, cc-legal-tools-data
Platform Toolkit /platform/toolkit Platform Toolkit mp
Public Domain /publicdomain CC Legal Tools cc-legal-tools-app, cc-legal-tools-data
WordPress / (default) Vocabulary Theme vocabulary-theme

Code of conduct

CODE_OF_CONDUCT.md:

The Creative Commons team is committed to fostering a welcoming community. This project and all other Creative Commons open source projects are governed by our Code of Conduct. Please report unacceptable behavior to [email protected] per our reporting guidelines.

Contributing

See CONTRIBUTING.md.

Docker containers

The docker-compose.yml file defines the following containers:

  1. index-composer - A Dependency Manager for PHP
    • This container does not have a persistent service. Expect the following message when you start the services: index-composer exited with code 0
  2. index-phpmyadmin - Database administration
  3. index-wpcli - The command line interface for WordPress
  4. index-web - Web server (WordPress and static HTML components)
  5. index-wpdb - Database server for WordPress

Setup

  1. Ensure the following repositories are cloned adjacent to this repository:
    PARENT_DIR
    ├── cc-legal-tools-data
    ├── chooser
    ├── dev-index-env
    ├── faq
    └── mp
    
  2. Create the .env file:
    cp .env.example .env
  3. Update .env to set desired values for variables (WP_VERSION, WP_MOD_TYPE, WP_MOD_NAME, etc.)
  4. Build/start Docker:
    docker compose up
  5. Wait for build and initialization to complete
  6. Setup WordPress:
    ./setup-wordpress.sh
  7. Optional (CC staff only): import production data
    1. Ensure you have access to the production server and your local machine is properly configured to access it
    2. Pull production data
      ./staff_migrate.sh pull
    3. Import production data
      ./staff_migrate.sh import

Path URLs

Path label Dev link Stage link Prod link
Chooser Dev /choose Stage /choose Prod /choose
FAQ Dev /faq Stage /faq Prod /faq
Licenses Dev /licenses Stage /licenses Prod /licenses
Platform Toolkit Dev /platform/toolkit Stage /platform/toolkit Prod /platform/toolkit
Public Domain Dev /publicdomain Stage /publicdomain Prod /publicdomain
WordPress Dev / (default) Stage / (default) Prod / (default)
WordPress Admin Dev /wp-admin Stage /wp-admin Prod /wp-admin

Dev configuration

Apache2

See config/web-sites-available/000-default.conf.

WordPress core

Name Version
WordPress 6.3

Also see .env.example.

WordPress plugins

Name Version
Advanced Custom Fields 6.2.1
Advanced Custom Fields: Menu Chooser 1.1.0
Classic Editor 1.6.3
Monster Insights Google Analytics 8.19
Redirection 5.3.10
Tablepress 2.1.7
Wordfence 7.10.4
WordPress Importer 0.8.1
Yoast SEO 21.2

Also see config/composer/composer.json.

WordPress themes

Name Version
Vocabulary Theme 1.3.3

Also see config/composer/composer.json.

Stage and Prod configuration

The staging server and production server are configured via Salt managed in the in creativecommons/sre-salt-prime repository. The list below include the specifics (is non-exhaustive):

Copying

CC0 1.0 Universal (CC0 1.0) Public Domain Dedication button

COPYING: All the content within this repository is dedicated to the public domain under the CC0 1.0 Universal (CC0 1.0) Public Domain Dedication.

index-dev-env's People

Contributors

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