Running platform local:build in Ubuntu, receive error below.
I've installed Ubuntu on Windows 10 Pro 64-bit via the Linux Sub-system for Windows. Then, I installed LAMP, Composer, and the Platform.sh CLI.
Now, I've performed a get on my project to check it out locally, and am performing a build on it locally. But this is what happens:
$ platform local:build
Building application m2 (runtime type: php:7.0)
Found a composer.json file; installing dependencies
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Your requirements could not be resolved to an installable set of packages.
Problem 1
- magento/framework 101.0.1 requires ext-gd * -> the requested PHP extension gd is missing from your system.
- magento/framework 101.0.1 requires ext-gd * -> the requested PHP extension gd is missing from your system.
- Installation request for magento/framework 101.0.1 -> satisfiable by magento/framework[101.0.1].
To enable extensions, verify that they are enabled in your .ini files:
-
- /etc/php/7.0/cli/conf.d/10-opcache.ini
- /etc/php/7.0/cli/conf.d/10-pdo.ini
- /etc/php/7.0/cli/conf.d/15-xml.ini
- /etc/php/7.0/cli/conf.d/20-calendar.ini
- /etc/php/7.0/cli/conf.d/20-ctype.ini
- /etc/php/7.0/cli/conf.d/20-curl.ini
- /etc/php/7.0/cli/conf.d/20-dom.ini
- /etc/php/7.0/cli/conf.d/20-exif.ini
- /etc/php/7.0/cli/conf.d/20-fileinfo.ini
- /etc/php/7.0/cli/conf.d/20-ftp.ini
- /etc/php/7.0/cli/conf.d/20-gettext.ini
- /etc/php/7.0/cli/conf.d/20-iconv.ini
- /etc/php/7.0/cli/conf.d/20-json.ini
- /etc/php/7.0/cli/conf.d/20-phar.ini
- /etc/php/7.0/cli/conf.d/20-posix.ini
- /etc/php/7.0/cli/conf.d/20-readline.ini
- /etc/php/7.0/cli/conf.d/20-shmop.ini
- /etc/php/7.0/cli/conf.d/20-simplexml.ini
- /etc/php/7.0/cli/conf.d/20-sockets.ini
- /etc/php/7.0/cli/conf.d/20-sysvmsg.ini
- /etc/php/7.0/cli/conf.d/20-sysvsem.ini
- /etc/php/7.0/cli/conf.d/20-sysvshm.ini
- /etc/php/7.0/cli/conf.d/20-tokenizer.ini
- /etc/php/7.0/cli/conf.d/20-wddx.ini
- /etc/php/7.0/cli/conf.d/20-xmlreader.ini
- /etc/php/7.0/cli/conf.d/20-xmlwriter.ini
- /etc/php/7.0/cli/conf.d/20-xsl.ini
You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode.
[ProcessFailedException]
The command failed with the exit code: 2
Full command: '/usr/local/bin/composer' 'install' '--no-progress' '--prefer-dist' '--optimize-autoloader' '--no-interaction' '--no-ansi'
Looks like the PHP-GD library was not installed or enabled on your local Ubuntu. Try installing it by:
sudo apt-get install php7.0-gd
Related
I have a manifest that looks like the below:
applications:
- name: sfcbackups-staging
memory: 1G
disk_quota: 4GB
instances: 1
buildpacks:
- https://github.com/cloudfoundry/apt-buildpack
- nodejs_buildpack
services:
- sfcstaging-db
And an apt.yml that looks like this to install Postgres
---
cleancache: true
keys:
- https://www.postgresql.org/media/keys/ACCC4CF8.asc
repos:
- deb https://apt.postgresql.org/pub/repos/apt/ bionic-pgdg main
packages:
- postgresql-client-11
But whenever I try running the command pg_dump (either via node or ssh) I get the following error:
Can't locate PgCommon.pm in #INC (you may need to install the PgCommon module)(#INC contains:
/etc/perl
/usr/local/lib/x86_64-linux-gnu/perl/5.26.1
/usr/local/share/perl/5.26.1
/usr/lib/x86_64-linux-gnu/perl5/5.26
/usr/share/perl5
/usr/lib/x86_64-linux-gnu/perl/5.26
/usr/share/perl/5.26
/usr/local/lib/site_perl
/usr/lib/x86_64-linux-gnu/perl-base)
at ./pg_dump line 22.
BEGIN failed--compilation aborted at ./pg_dump line 22.
There's a couple of things I have tried so far but to no avail:
Added the following to my apt.yml
- libdbd-pg-perl
- libpq-dev
Running cpan install DBD::Pg (via SSH) to see if this would fix the issue however the same error occurs.
Has anyone had any similar issues?
Thanks in advance
I try to deploy the rails 6 App on platform.sh,
I have this error when deploying my project in Rails 6 with Webpacker 5.2.1.
I have done days of research on google, without success.
I have NVM installed locally, node and npm, I will say that everything is fine locally, the webpacker is compiled correctly, but not on the remote machine.
and this error makes the deployment fail.
W: Webpacker requires Node.js ">=10.17.0" and you are using v6.17.1
W: Please upgrade Node.js https://nodejs.org/en/download/
W: Exiting!
E: Error building project: Step failed with status code 1.
E: Error: Unable to build application, aborting.
when I want to compile the assets with this line on Build hook.
RAILS_ENV=production bundle exec rails webpacker:install
can you help me
I'll share my config
.platform.app.yaml
# The name of this app. Must be unique within a project.
name: app
type: 'ruby:2.7'
mounts:
log:
source: local
source_path: log
tmp:
source: local
source_path: tmp
relationships:
postgresdatabase: 'dbpostgres:postgresql'
# The size of the persistent disk of the application (in MB).
disk: 1024
hooks:
build: |
bundle install --without development test
RAILS_ENV=production bundle exec rails webpacker:install
deploy: |
RAILS_ENV=production bundle exec rake db:migrate
web:
upstream:
socket_family: "unix"
commands:
start: "unicorn -l $SOCKET -E production config.ru"
locations:
'/':
root: "public"
passthru: true
expires: 1h
allow: true
services.yaml
dbpostgres:
# The type of your service (postgresql), which uses the format
# 'type:version'. Be sure to consult the PostgreSQL documentation
# (https://docs.platform.sh/configuration/services/postgresql.html#supported-versions)
# when choosing a version. If you specify a version number which is not available,
# the CLI will return an error.
type: postgresql:13
# The disk attribute is the size of the persistent disk (in MB) allocated to the service.
disk: 9216
configuration:
extensions:
- plpgsql
- pgcrypto
- uuid-ossp
routes.yaml
# Each route describes how an incoming URL is going to be processed by Platform.sh.
"https://www.{default}/":
type: upstream
upstream: "app:http"
"https://{default}/":
type: redirect
to: "https://www.{default}/"
I am currently working on a Angular application which I plan on running on a Raspberry Pi. But, when trying to start the application, the following error occurs:
An unhandled exception occurred: Cannot find module 'source-map'
Require stack:
- /home/pi/Desktop/SESAME/SESAME/src/tailwind/node_modules/#angular-devkit/core/src/utils/template.js
- /home/pi/Desktop/SESAME/SESAME/src/tailwind/node_modules/#angular-devkit/core/src/utils/index.js
- /home/pi/Desktop/SESAME/SESAME/src/tailwind/node_modules/#angular-devkit/core/src/experimental/jobs/create-job-handler.js
- /home/pi/Desktop/SESAME/SESAME/src/tailwind/node_modules/#angular-devkit/core/src/experimental/jobs/index.js
- /home/pi/Desktop/SESAME/SESAME/src/tailwind/node_modules/#angular-devkit/core/src/experimental.js
- /home/pi/Desktop/SESAME/SESAME/src/tailwind/node_modules/#angular-devkit/core/src/index.js
- /home/pi/Desktop/SESAME/SESAME/src/tailwind/node_modules/#angular-devkit/architect/src/architect.js
- /home/pi/Desktop/SESAME/SESAME/src/tailwind/node_modules/#angular-devkit/architect/src/index.js
- /home/pi/Desktop/SESAME/SESAME/src/tailwind/node_modules/#angular-builders/custom-webpack/dist/dev-server/index.js
- /usr/local/lib/node_modules/#angular/cli/node_modules/#angular-devkit/architect/node/node-modules-architect-host.js
- /usr/local/lib/node_modules/#angular/cli/node_modules/#angular-devkit/architect/node/index.js
- /usr/local/lib/node_modules/#angular/cli/models/architect-command.js
- /usr/local/lib/node_modules/#angular/cli/commands/serve-impl.js
- /usr/local/lib/node_modules/#angular/cli/node_modules/#angular-devkit/schematics/tools/export-ref.js
- /usr/local/lib/node_modules/#angular/cli/node_modules/#angular-devkit/schematics/tools/index.js
- /usr/local/lib/node_modules/#angular/cli/utilities/json-schema.js
- /usr/local/lib/node_modules/#angular/cli/models/command-runner.js
- /usr/local/lib/node_modules/#angular/cli/lib/cli/index.js
- /usr/local/lib/node_modules/#angular/cli/lib/init.js
- /usr/local/lib/node_modules/#angular/cli/bin/ng
See "/tmp/ng-SQBaqf/angular-errors.log" for further details.
I have tried:
To uninstall and re-install angular cli
To install all dependencies
with npm install
To run npm install #types/source-map#0.5.2, as suggested here
How does one resolve it?
Have you already tried deleting the node_modules directory and running npm install afterwards?
How do i setup a node.js project in Jenkins Blue Ocean?
I keep getting a "command not found"
I installed a NodeJS version.
For the Pipeline settings i set
Agent - any
For Init / Provide Node & npm bin/ folder to PATH i set
NodeJSInstallationName* - nw
ConfigId - none
Child steps - Print Message
Fixed by installing NodeJS on local machine.
I'm running Debian 9.1 and I want to configure my VPS on creation by using cloud-init and I have a particular configuration problem.
This is the default values of cloud.cfg from the provided snapshot:
# The modules that run in the 'init' stage
cloud_init_modules:
- migrator
- seed_random
- bootcmd
- write-files
- growpart
- resizefs
- disk_setup
- mounts
- set_hostname
- update_hostname
- update_etc_hosts
- ca-certs
- rsyslog
- users-groups
- ssh
# The modules that run in the 'config' stage
cloud_config_modules:
# Emit my cloud config ready event
# this can be used by upstart jobs for 'start on cloud-config'.
- emit_upstart
- ssh-import-id
- locale
- set-passwords
- grub-dpkg
- apt-pipelining
- apt-configure
- ntp
- timezone
- disable-ec2-metadata
- runcmd
- byobu
# The modules that run in the 'final' stage
cloud_final_modules:
- package-update-upgrade-install
- fan
- puppet
- chef
- salt-minion
- mcollective
- rightscale_userdata
- scripts-vendor
- scripts-per-once
- scripts-per-boot
- scripts-per-instance
- scripts-user
- ssh-authkey-fingerprints
- keys-to-console
- phone-home
- final-message
- power-state-change
As you can see, runcmd will be executed in the config stage, after apt-configure.
As part of my configuration I'm installing multiple packages, one of which requires that I add a new source and to import a key from a keyserver. There's a problem because importing a key requires dirmngr to be installed on the system but Debian 9.1 doesn't have it installed by default.
However, since apt-configure is executed before runcmd, I can't install dirmngr before trying to import a key. As a result, the rest of the configuration will fail and the system will be in an unwanted state.
How can I get around this problem?
Regarding the specific case of missing dirmngr package on Debian 9.1 causing failure of the apt-configure module, I have had success with adding the following bootcmd entry to my cloud-init configuration:
# APT fails to acquire GPG keys if package dirmngr is missing
bootcmd:
- [ cloud-init-per, once, dirmngr-aptupdate, apt-get, update ]
- [ cloud-init-per, once, dirmngr-aptinstall, apt-get, install, dirmngr ]
Since the cloud-init configuration is obtained from the network (I'm using EC2 userdata), network is guaranteed to be up when bootcmd is executed. The cloud-init-per program make it easy to ensure that these commands are not reexecuted on further instance boot.