Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • CiviCRM Core CiviCRM Core
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Graph
    • Compare
  • Issues 1,258
    • Issues 1,258
    • List
    • Boards
    • Service Desk
    • Milestones
  • Deployments
    • Deployments
    • Releases
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • DevelopmentDevelopment
  • CiviCRM CoreCiviCRM Core
  • Wiki
  • standalone

standalone · Changes

Page history
Update standalone authored Dec 17, 2021 by bgm's avatar bgm
Hide whitespace changes
Inline Side-by-side
standalone.md
View page @ 4d85deef
......@@ -73,7 +73,7 @@ Presumably we will want some sort of composer template, so that people can also
Since the installer does not work, generate manually:
```
```https://github.com/civicrm/civicrm-core/pull/22227
cd /var/www/standalone/
cp vendor/civicrm/civicrm-core/templates/CRM/common/civicrm.settings.php.template civicrm.settings.php
```
......@@ -98,41 +98,10 @@ $civicrm_paths['civicrm.bower']['path'] = '/var/www/standalone/web/assets/civicr
## Initialize the database
### Using GenCode
* Manually create a civicrm.config.php in vendor/civicrm/civicrm-core
Assuming you have applied [this patch](https://github.com/civicrm/civicrm-core/pull/22227) on civicrm-core:
```php
<?php
$settingsFile = '/path/to/civi-standalone/civicrm.settings.php';
define('CIVICRM_SETTINGS_PATH', $settingsFile);
$error = @include_once( $settingsFile );
if ( $error == false ) {
echo "Could not load the settings file at: {$settingsFile}\n";
exit( );
}
```
### Using GenCode
* Apply this patch to vendor/civicrm/civicrm-core
```diff
--- CRM/Core/CodeGen/Config.php.orig
+++ CRM/Core/CodeGen/Config.php
@@ -16,11 +16,12 @@
'drupal8',
'joomla',
'wordpress',
+ 'standalone',
])) {
echo "Config file for '{$this->config->cms}' not known.";
exit();
}
- elseif ($this->config->cms !== 'joomla') {
+ elseif ($this->config->cms !== 'joomla' && $this->config->cms !== 'standalone') {
$configTemplate = $this->findConfigTemplate($this->config->cms);
if ($configTemplate) {
echo "Generating civicrm.config.php\n";
```
* Run `cd xml && php GenCode.php 0 0 Standalone`
* Then you can use the civicrm.mysql and civicrm_data.mysql files in sql (or if you want sample data you can use civicrm_generated.mysql instead of civicrm_data.mysql).
......@@ -145,7 +114,7 @@ cat vendor/civicrm/civicrm-core/sql/civicrm_data.mysql | mysql -u civitest -p ci
# Example nginx vhost
(adapt to your environment)
(adapt to your environment, this example uses php-8.0)
```
server {
......@@ -159,7 +128,6 @@ server {
try_files $uri 404;
}
# Redirect to main GERT site
location / {
return 301 https://test.example.org$uri;
}
......@@ -222,12 +190,13 @@ server {
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
}
```
For apache in addition to setting up the virtual host, you can then put the stock Drupal 7 .htaccess in web.
# Menubar notes
(edit ML: this should be fixed in PR 22227)
* Need to create a dummy file css/menubar-standalone.css
* If you comment out the `$contactID` part from this line in CRM/Core/Resources/Common.php then it will try to do the menubar, but there's still js errors because crm-l10n isn't being generated correctly: `$contactID && !CRM_Core_Config::singleton()->userFrameworkFrontend`.
\ No newline at end of file
Clone repository
  • CiviCRM v5.49 Schedule Reminder Notice
  • CiviEvent v5.47 Timezone Notice
  • Event Time Zone Implementation Planning
  • Replacing AngularJS
  • Testy tests
  • afform security
  • Home
  • issue labels
  • message templates
  • sample data
  • standalone
  • utf8mb4