Coder Social home page Coder Social logo

hu19891110 / magento-cloud Goto Github PK

View Code? Open in Web Editor NEW

This project forked from magento/magento-cloud

0.0 3.0 0.0 13.78 MB

Magento Cloud

License: Open Software License 3.0

ApacheConf 0.09% PHP 58.08% HTML 25.11% CSS 7.09% JavaScript 9.53% XSLT 0.08% Shell 0.02%

magento-cloud's Introduction

Magento 2.1.0 Enterprise Cloud Edition

This sample repository helps you deploy a Magento 2.1.0 Enterprise Edition (EE) instance in the cloud. You must be a licensed user of Magento Enterprise Cloud Edition to use the example in this repository.

This example is based on using the Composer to load dependencies and get the Magento vendor folders.

Create an authorization file

To enable you to install and update the Magento software, you must have an auth.json file in your project's root directory. auth.json contains your Magento EE authorization credentials.

In some cases, you might already have auth.json so check to see if it exists and has your authentication credentials before you create a new one.

To create a new auth.json in the event you don't have one:

  1. Copy the provided sample using the following command:

    cp auth.json.sample auth.json
    
  2. Open auth.json in a text editor.

  3. Replace <public-key> and <private-key> with your authentication credentials.

    See the following example:

    "http-basic": {
       "repo.magento.com": {
          "username": "<public-key>",
          "password": "<private-key>"
        }
    }
    
  4. Save your changes to auth.json and exit the text editor.

Required changes for release 101.0.2

The 101.0.2 release on August 5, 2016 requires you to make some manual changes to the following files, which are both located in your project root directory:

  • .magento.app.yaml, the main project configuration file.
  • composer.json, which specifies project dependencies.

Changes are discussed in the sections that follow.

.magento.app.yaml

Open .magento.app.yaml in a text editor and update the build section (which is nested in the deploy section) and crons sections as follows:

deploy section

deploy: |
    php ./vendor/magento/magento-cloud-configuration/pre-deploy.php
    php ./bin/magento magento-cloud:deploy

crons section

crons:
        cronrun:
            spec: "*/5 * * * *"
            cmd: "php bin/magento cron:run && php bin/magento cron:run"

composer.json

Open composer.json and update the "files" directive in the autoload section as follows:

"autoload": {
        "psr-4": {
            "Magento\\Framework\\": "lib/internal/Magento/Framework/",
            "Magento\\Setup\\": "setup/src/Magento/Setup/",
            "Magento\\": "app/code/Magento/"
        },
        "psr-0": {
            "": "app/code/"
        },
        "files": [
            "app/etc/NonComposerComponentRegistration.php"
        ]
    }

Move app/NonComposerComponentRegistration.php to app/etc/NonComposerComponentRegistration.php. Make sure the relative paths that point to locations in the app and lib directories reflect the new location of the file. For an example that can be copied, see the copy in this project.

Update the require section as follows to:

  • Replace "magento/product-enterprise-edition": "<current version>", with "magento/magento-cloud-metapackage": "<upgrade version>",
  • Remove "magento/magento-cloud-configuration": "1.0.*",

(In some cases, your composer.json might already be correct.)

 },
    "require": {
        "magento/magento-cloud-metapackage": "2.1.0",
        "composer/composer": "@alpha",
        "colinmollenhour/credis": "1.6",
        "colinmollenhour/php-redis-session-abstract": "1.1",
        "fastly/magento2": "^1.0"
    },

Run composer update, and make sure the updated composer.lock and other changed files are checked in to git.

Repository structure

Here are the specific files for this example to work on Magento Enterprise Cloud Edition:

.magento/
         /routes.yaml
         /services.yaml
.magento.app.yaml
auth.json
composer.json
magento-vars.php
php.ini

.magento/routes.yaml redirects www to the naked domain, and that the application that will be serving HTTP is named php.

.magento/services.yaml sets up a MySQL instance, plus Redis and Solr.

composer.json fetches the Magento Enterprise Edition and some configuration scripts to prepare your application.

Documentation

For more details, see our Magento Enterprise Cloud Guide.

Get started here.

magento-cloud's People

Contributors

bwaters avatar dsikkema-magento avatar guguss avatar kazanir avatar vrann avatar

Watchers

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