Issue Repeated
The other day I was encountering a GovCMS PaaS client with very odd code-base, deplpying on my local computer first require my GitHub ghp_xxxxxxxx authentication key (solved via adding docker-compose.override.yml
file), then it raised an issue of "/usr/local/bin/drush": not found
(solved via uncommenting lines in Dockerfile.cli
file), then I found its scaffold to be outdated (solved via updating .version.yml
scaffold version number) …
Even after all these patches, once I run ahoy up, the website still cannot run properly. All the associated docker container starts as I run pygmy up && ahoy build
as expected, but soon as the build process finishes, the nginx-1
container magically kills/pauses itself with the following error:
|
|
Causing all of its reqeust to the url to be unsesolved 503 Service Unavailable
:
Issue Resolved
When it comes to situations where you are unable to run the actual website directly on your computer, whether due to technical limitations, resource constraints, or compatibility issues, it can be quite challenging. I’ve found it universal solution that can work on almost any website “broken” due to the filebase (but not database).
Initializing GovCMS Scaffold
To begin with, install an empty scaffold by cloning from https://github.com/govCMS/scaffold, and initialize the empty scaffold with the same type (SaaS
/PaaS
), same version (8
/9
/10
), but slightly different project_name (e.g. suffix _scaffold
).
For instance:
|
|
And make it running by running the follows:
|
|
In theory, once all these steps are completed, you should receive a URL that, when opened, will appear as follows:
Copy Themes Folder (PaaS and SaaS)
Once you got your empty scaffold working, you will need to copy everything within web/themes
folder of the “broken” website’s filebase, to the web/themes
folder of the empty scaffold. Usually there’re two files and two folders:
|
|
Copy Modules Folder (PaaS only)
After the theme folder is migrated, for PaaS environment, you will need to also copy over the custom/contributed modules you have used, those modules are located at web/modules
folder, copy them to the web/modules
folder of the empty scaffold as well, an example of the hierarchy of the folder is as follows:
|
|
(it is just a shortcut I choose to use, you may also migrate the conrtibuted modules via updating the relevant composer.json
file and run composer install
)
Ahoy Import Database (PaaS and SaaS)
Lastly you will need to import the database of the website to the empty scaffold:
|
|
Get the setup scaffold’s URL via ahoy info
, and in theory, the “brand new” site will no longer suffer from the issues of the original broken site.
Topic Alias (for Search Purpose)
- GovCMS Ahoy Issue Fallback Solution
- GovCMS Local Install Issue Fallback Solution
- GovCMS Docker Issue Fallback Solution