Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rebased 'master' onto 'production' #13

Merged
merged 63 commits into from
Nov 21, 2024
Merged
Show file tree
Hide file tree
Changes from 61 commits
Commits
Show all changes
63 commits
Select commit Hold shift + click to select a range
de08171
.gitignore: Remove remnants of debug-bar
rebeccahum Dec 15, 2022
6d31a77
Merge pull request #94 from Automattic/debug_bar_deprecation
rebeccahum May 1, 2023
43d86ca
Bump down WP_POST_REVISIONS to 100, add a link to the technical refer…
rinatkhaziev May 1, 2023
f1f4a26
Update Twenty Twenty Two to v1.4
gamebits May 20, 2023
8655e51
Restores deleted files
gamebits May 20, 2023
6183695
Update Twenty Twenty Three to v1.1
gamebits May 20, 2023
44430ff
Merge pull request #95 from Automattic/update/100-revs
rinatkhaziev May 25, 2023
336bcdb
Merge pull request #98 from Automattic/update/twentytwentythree-11
rinatkhaziev May 25, 2023
9d7307b
Merge pull request #97 from Automattic/update/twentytwentytwo-14
rinatkhaziev May 25, 2023
ab0322b
Composer: Update VIPCS to ^3
GaryJones Sep 5, 2023
4ba729c
PHPCS: Refresh minimum PHP and WP versions
GaryJones Sep 5, 2023
1425d79
Merge pull request #100 from Automattic/add/vipcs-3.0.0
GaryJones Sep 5, 2023
8fa4534
Add new theme twentytwentyfour (#104)
rebeccahum Nov 7, 2023
bdc845e
Update Twenty Twenty Two to v1.4 (#103)
gamebits Nov 7, 2023
82c3f47
Update Twenty Twenty Three to v1.2 (#102)
gamebits Nov 7, 2023
0d1acf5
Release codespaces publicly
rinatkhaziev Dec 21, 2023
5060ee2
Formatting
rinatkhaziev Dec 21, 2023
f17dba0
Apply readme suggestions from review + add some more
rinatkhaziev Jan 12, 2024
f25a981
Applying suggestions from review
rinatkhaziev Jan 12, 2024
09dda73
Update README.md - rephrase prerequisites
rinatkhaziev Jan 22, 2024
37c6df2
Merge pull request #105 from Automattic/add/codespaces
Crixu Jan 30, 2024
bb8fd67
Disable Divi caching platform wide
kat3samsin May 17, 2024
14bff7d
Revert commit of divi cache
kat3samsin May 17, 2024
5d4f28a
Merge branch 'production' of https://github.com/Automattic/vip-go-ske…
kat3samsin May 17, 2024
03842b3
Revert commit of divi cache
kat3samsin May 17, 2024
6210d9f
Update doc links (#113)
gamebits Sep 3, 2024
ae446c9
Update Twenty Twenty Two to v1.8 (#110)
gamebits Sep 3, 2024
38d49fe
Update Twenty Twenty Four to v1.4 (#112)
gamebits Sep 3, 2024
00d374f
Update Twenty Twenty Three (#111)
gamebits Sep 22, 2024
dc72ba2
Update vip-config.php
brianalvey Sep 23, 2024
cd4f365
Comment out revisions constants
mjangda Sep 23, 2024
f491baa
Merge pull request #114 from Automattic/brianalvey-unlimited-post-his…
rinatkhaziev Sep 23, 2024
559d765
Add new theme 2025
rebeccahum Nov 12, 2024
9a055e8
Merge pull request #115 from Automattic/add/2025
rinatkhaziev Nov 12, 2024
9c096e2
Update Twenty Twenty Two to v1.9 (#116)
gamebits Nov 18, 2024
6861195
Update Twenty Twenty Four to v1.3 (#118)
gamebits Nov 18, 2024
7ec136b
Update Twenty Twenty Three to v1.6 (#117)
gamebits Nov 18, 2024
6ea3754
Add environments, maintainers and development workflow details in REA…
chandrapatel May 27, 2020
33769d7
Add phpcs.xml file
chandrapatel May 27, 2020
07b20ee
Add Github actions for phpcs scan and auto deployment
chandrapatel May 27, 2020
8d0da48
Update .gitignore file
chandrapatel May 27, 2020
f9aad8d
Update checkout action to stable tag
rtBot Jul 28, 2020
95d8c10
Update WordPress core to 5.5
rtBot Aug 12, 2020
aa1e692
Update site visibility to private after data-sync for non-prod site
dishitpala Oct 9, 2020
d2393c2
Remove vault dependency from workflows
rtBot Sep 10, 2020
8fa907e
Update development workflow
chandrapatel Oct 13, 2020
c84d321
Update deploy on push yml file to add vip-go mu-plugins
chandrapatel Nov 12, 2020
a2e7783
Block crawling and disable two factor authentication for non-producti…
chandrapatel Oct 16, 2020
31b3120
Revert "Update site visibility to private after data-sync for non-pro…
chandrapatel Oct 16, 2020
fbc9057
Update action versions and runner machine
mrrobot47 Nov 16, 2020
b4bc319
Add cleanup required for self-hosted runners
mrrobot47 Nov 16, 2020
1846036
Update WP version to 5.8.2
PiyushKhurana Nov 26, 2021
e299fa9
Update PHP test version and exclude twentytwentytwo theme from scan
chandrapatel Jun 17, 2022
67d7b56
Add vip-gutenberg-content-api plugin
alecgeatches Jan 13, 2023
7828ffe
Add test client side block plugin
alecgeatches Jan 13, 2023
3c77fc0
Revert "Add test client side block plugin"
alecgeatches Jan 13, 2023
bb75254
Revert "Add vip-gutenberg-content-api plugin"
alecgeatches Jan 13, 2023
bd1f1f0
Switch to high-performance runners for phpcs scan
mrrobot47 Apr 6, 2023
7233c37
Update deploy_on_push.yml
MiteshShah Apr 18, 2024
868cadc
Add dependabot.yml file
L0RD-ZER0 Sep 16, 2024
97fe79b
Update SSH key for ED
mrrobot47 Nov 13, 2024
6bab018
- Updated github checkout action version to v4
divyarajmasani Nov 21, 2024
212ce54
Merge branch 'master' into rebased/production
divyarajmasani Nov 21, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
21 changes: 21 additions & 0 deletions .devcontainer/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Codespaces for WordPress VIP

The provided `devcontainer.json` file is configured to create a Codespaces development environment that is as identical as possible to a VIP Platform environment.

Read our documentation to learn how to get started and [work with Codespaces for WordPress VIP applications](https://docs.wpvip.com/local-development/developing-with-github-codespaces/).

Refer to [GitHub's documentation for Codespaces](https://docs.github.com/en/codespaces) to learn more about Codespaces in general.

## Quick Start

From within the GitHub interface for a repository with the `devcontainer.json` file:

1. Select the button labeled "**<> Code**".
2. Select the tab labeled "**Codespaces**".
3. Select the button labeled "**Create codespace**". A displayed output log in a new browser tab will report progress on the creation of the new codespace (first-time creation might take a few minutes).

## Prerequisites

- Use of Codespaces within the wpcomvip GitHub organization is available as a part of our Enhanced and Premier packages. Qualifying customers must create a [VIP Support request](https://wordpressvip.zendesk.com/) for the Codespaces feature to be enabled for their GitHub user account.
- To work with Codespaces outside of the wpcomvip organization, customers can copy the [.devcontainer/devcontainer.json](https://github.com/Automattic/vip-go-skeleton/raw/5060ee2506c7baca258cd10f708a335162ab4937/.devcontainer/devcontainer.json) file to their own GitHub repository.
- A user must have a GitHub user role with Write access within the repository where Codespaces is used.
173 changes: 173 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,173 @@
{
"name": "WordPress VIP Codespace",
"image": "ghcr.io/automattic/vip-codespaces/alpine-base:latest",
"overrideCommand": false,
"forwardPorts": [80, 81, 8025],
"portsAttributes": {
"80": {
"label": "Application",
"onAutoForward": "notify",
"elevateIfNeeded": true
},
"81": {
"label": "phpMyAdmin",
"onAutoForward": "notify",
"elevateIfNeeded": true
},
"1025": {
"label": "Mailpit SMTP",
"onAutoForward": "ignore"
},
"3306": {
"label": "MySQL",
"onAutoForward": "ignore"
},
"8025": {
"label": "Mailpit",
"onAutoForward": "notify"
},
"9000": {
"label": "php-fpm",
"onAutoForward": "ignore"
},
"9003": {
"label": "Xdebug Client Port",
"onAutoForward": "notify"
}
},
"features": {
// *************************
// *** Required features ***
// *************************
"ghcr.io/automattic/vip-codespaces/base:latest": {},
"ghcr.io/automattic/vip-codespaces/nginx:latest": {
// Set to the URL of a VIP Platform site where requests for missing media files can be redirected.
// Example: "mediaRedirectURL": "https://example.com"
"mediaRedirectURL": ""
},
"ghcr.io/automattic/vip-codespaces/php:latest": {
// PHP version options: 8.1, 8.2, 8.3
"version": "8.2",
"composer": true
},
"ghcr.io/automattic/vip-codespaces/mariadb:latest": {
// Set to false to prevent the database content from persisting between rebuilds.
"installDatabaseToWorkspaces": true
},
"ghcr.io/automattic/vip-codespaces/wordpress:latest": {
// WordPress version: Accepts 'latest', 'nightly', or a version number.
"version": "latest",
// Set to false to prevent wp-content/uploads content from persisting between rebuilds.
"moveUploadsToWorkspaces": true,
// Set to true to create the environment as a WordPress multisite.
"multisite": false,
// GitHub Codespaces only supports the subdirectory network type for multisite; subdomain cannot be used.
"multisiteStyle": "subdirectory"
},
"ghcr.io/automattic/vip-codespaces/wp-cli:latest": {
// Set to true to enable nightly builds of WP-CLI.
"nightly": false
},
"ghcr.io/automattic/vip-codespaces/vip-go-mu-plugins:latest": {
// Set to false to disable VIP MU plugins (not recommended).
"enabled": true,
// Which branch of VIP MU plugins to load. Accepts 'staging', 'production', or 'develop'.
"branch": "staging",
// Set to true to load all files necessary for the development of VIP MU plugins.
"development_mode": false
},
"ghcr.io/automattic/vip-codespaces/dev-tools:latest": {},
// *************************
// *** Optional features ***
// *************************
"ghcr.io/automattic/vip-codespaces/memcached:latest": {
// Set to false to disable memcached and the object cache (this is not recommended).
"enabled": true
},
"ghcr.io/automattic/vip-codespaces/vip-cli:latest": {
// Set to false to disable VIP-CLI.
"enabled": true,
// Which version of VIP-CLI to install. Accepts 'latest', 'next', or a version number (see https://www.npmjs.com/package/@automattic/vip?activeTab=versions).
"version": "latest"
},
// Photon
"ghcr.io/automattic/vip-codespaces/photon:latest": {
// Set to false if you don't need Photon
"enabled": true,
// Set to false to enable image optimizations. This may slow down requests.
"disable_optimizations": true,
// Process images only if they have a query string in their URLs
// When set to true:
// * https://mysite.com/wp-content/uploads/image.jpg will not be processed
// * https://mysite.com/wp-content/uploads/image.jpg?w=100 will be processed
// When set to false, both images will be processed by Photon.
"only_images_with_qs": true
},
// Elasticsearch
"ghcr.io/automattic/vip-codespaces/elasticsearch:latest": {
// Set to true to enable Elasticsearch.
// This feature requires the local machine to have at least 8 GB RAM.
"enabled": false,
// Set to false to prevent Elasticsearch data from persisting between rebuilds.
"installDataToWorkspaces": true
},
// Cron
"ghcr.io/automattic/vip-codespaces/cron:latest": {
// Set to true to enable cron.
"enabled": false,
// If system cron is enabled, additional settings are available.
// Set to false to cancel the creation of a system cron task that runs WordPress cron.
"run_wp_cron": true,
// WordPress cron schedule. Refer to https://crontab.guru/ for cron schedule expressions.
"wp_cron_schedule": "*/15 * * * *"
},
// Tools
"ghcr.io/automattic/vip-codespaces/mailpit:latest": {
// Set to false to disable Mailpit.
"enabled": true
},
"ghcr.io/automattic/vip-codespaces/phpmyadmin:latest": {
// Set to false to disable phpMyAdmin.
"enabled": true
},
// Debugging
"ghcr.io/automattic/vip-codespaces/xdebug:latest": {
// Set to true to enable Xdebug.
// This setting can also be updated with CLI commands in the terminal.
"enabled": false,
// Set Xdebug mode. Accepted value options are listed here: https://xdebug.org/docs/all_settings#mode
"mode": "debug"
},
// Misc
"ghcr.io/automattic/vip-codespaces/mc:latest": {
// Set to true to enable Midnight Commander.
"enabled": false
},
"ghcr.io/automattic/vip-codespaces/ssh:latest": {
// Set to true to enable an SSH server for the Codespaces environment.
"enabled": false
}
},
// *****************************
// *** Environment variables ***
// *****************************
"containerEnv": {
// "MY_VAR": "example",
// "MY_OTHER_VAR": "another example"
},
"customizations": {
"vscode": {
"extensions": [
"dlech.chmod",
"dbaeumer.vscode-eslint",
"GitHub.copilot",
"esbenp.prettier-vscode",
"timonwong.shellcheck",
"ms-azuretools.vscode-docker",
"zhiayang.tabindentspacealign",
"emilast.LogFileHighlighter",
"automattic.logwatcher"
]
}
}
}
31 changes: 31 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
---
name: "Bug Report"
about: "If something isn't working as expected"
title: ''
labels: ''
assignees: ''
---

## Bug Report

**Current Behavior**
A clear and concise description of the buggy behavior.

**Expected behavior/code**
A clear and concise description of what you expected to happen (or code).

**Steps to reproduce the bug**
Steps to reproduce if any.

**Testing Environment (if applicable)**

- Browser used
- OS: [e.g. OSX 10.15.x, Ubuntu 18.04]
- Browser used
- ...

**Possible Solution**
<!--- Only if you have suggestions on a fix for the bug -->

**Additional context/Screenshots**
Add any other context about the problem here. If applicable, add screenshots to help explain.
22 changes: 22 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
name: "\U0001F680 Feature Request"
about: "Suggest an idea for this project."
title: ''
labels: ''
assignees: ''
---

## Feature Request

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I have an issue when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen. Add any considered drawbacks.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Documentation, Adoption, Migration Strategy (if applicable)**
If you can, explain how users will be able to use this and possibly write out a version of the docs.
Maybe a screenshot or design?
8 changes: 8 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
version: 2
updates:
- package-ecosystem: github-actions
directory: /
schedule:
interval: weekly
reviewers:
- mrrobot47
18 changes: 18 additions & 0 deletions .github/hosts.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Environment name which should equal to Git branch name
master:

# SSH user to be used in deployment
user: www-data

# Server hostname or IP address for deployment
hostname: prod.example.com

# Path to deploy.
deploy_path: /opt/easyengine/sites/prod.example.com/app/htdocs


# Another environment. You can have as many as possible
develop:
user: www-data
hostname: dev.example.com
deploy_path: /opt/easyengine/sites/dev.example.com/app/htdocs
35 changes: 35 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
**IMPORTANT: Please do not create a Pull Request without creating an issue first.**

<!-- Make sure to add the issue number in Title. -->

## Types of changes

What types of changes do your code introduce to the project?
_Put an `x` in the boxes that apply_

- [ ] Bugfix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] Documentation Update

## Details

- How this issue fixed/resolved
- Feature implemented

## Checklist

_Put an `x` in the boxes that apply._

- [ ] Lint and tests pass locally with my changes
- [ ] I have added necessary documentation (if appropriate)

## Further comments (if needed)

If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc...

## Closing issues

Fixes: #ISSUE_NUMBER (For bug reports)
or
Closes: #ISSUE_NUMBER (For feature requests)
27 changes: 27 additions & 0 deletions .github/workflows/deploy_on_push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
on:
push:
branches:
- develop

name: Deploy and Slack Notification
jobs:
deploy:
name: Deploy
# Change below line to: `runs-on: ubuntu-latest` if not using self-hosted runners or if it is a public repo.
runs-on: self-hosted
steps:
- uses: actions/checkout@v2
divyarajmasani marked this conversation as resolved.
Show resolved Hide resolved
- name: Deploy
uses: rtCamp/action-deploy-wordpress@master
env:
SSH_PRIVATE_KEY: ${{ secrets.ED_DEPLOYMENT_KEY }}
WP_VERSION: latest
MU_PLUGINS_URL: vip
- name: Slack Notification
uses: rtCamp/action-slack-notify@master
env:
SLACK_CHANNEL: test
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
- name: Cleanup
if: ${{ always() }}
uses: rtCamp/action-cleanup@master
21 changes: 21 additions & 0 deletions .github/workflows/phpcs_on_pull_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
on: pull_request
name: Inspections
jobs:
runPHPCSInspection:
name: Run PHPCS inspection
# Change below line to: `runs-on: ubuntu-latest` if not using self-hosted runners or if it is a public repo.
runs-on: high-performance
steps:
- uses: actions/checkout@v2
divyarajmasani marked this conversation as resolved.
Show resolved Hide resolved
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: Run PHPCS inspection
uses: rtCamp/action-phpcs-code-review@master
env:
SKIP_FOLDERS: "tests,.github"
GH_BOT_TOKEN: ${{ secrets.RTBOT_TOKEN }}
with:
args: WordPress,WordPress-Core,WordPress-Docs
- name: Cleanup
if: ${{ always() }}
uses: rtCamp/action-cleanup@master
13 changes: 11 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ node_modules
/plugins/akismet/
/plugins/advanced-post-cache/
/plugins/cron-control/
/plugins/debug-bar/
/plugins/debug-bar-cron/
/plugins/gutenberg-ramp/
/plugins/jetpack/
/plugins/jetpack-force-2fa/
Expand All @@ -28,6 +26,7 @@ node_modules

# mu-plugins; these are managed at the platform-level
/mu-plugins/
mu-plugins

# drop-ins; these are managed at the platform-level
/object-cache.php
Expand All @@ -47,3 +46,13 @@ phpcs.xml

# Composer (repo root only)
/vendor/
debug.log
/node_modules/
node_modules

# Ignore editor config
.idea/
.vscode/

# Other files and folders
*.map
Loading
Loading