I want ask the question.
I want to deploy from github to nginx server using jenkins. Maybe you can help me with this? When i try to add in Jenkins setting Publish over SSH i have error
jenkins.plugins.publish_over.BapPublisherException: Failed to add SSH key. Message [invalid privatekey: [B#2a8ec46d]
I just started to study these technologies and most likely I am doing something wrong. Maybe i need configure my nginx files?
Also please tell me something links maybe with Guid how to deploy from GitHub using Jenkins and Nginx.
check this question from StackOverflow, someone faced the same problem and solution provided.
Check first (in addition of my old answer already mentioned) if you need to add to your SSH daemon config file (/etc/ssh/sshd_config), as seen in jenkinsci/publish-over-ssh-plugin issue 94:
PubkeyAuthentication yes
PubkeyAcceptedKeyTypes=+ssh-rsa
Related
Hey this is my first question on here, so go easy.
I set up a Nextcloud server on my homelab in an ubuntu server 20.04 vm using the snap install. I have a seperate vm running nginx as a reverse proxy to my Nextcloud instance. Everything works flawlessly as intended, except that when I try and install apps on Nextcloud, I get a curl error #7. I've tried using my lan ip through the web ui, my public domain name through the web ui, and the commandline using the nextcloud.occ app:install command. I always get the same error. I tried to find the appropriate log file to get more information but looking in /var/snap/nextcloud/current/log/ I couldn't find any relevant info in any of the logs. Running php -m comes up with php not installed, I guess because php is installed via the Nextcloud snap? Obviously php is installed somewhere because Nextcloud is running, but I don't know how to look and see what modules are enabled, or how to install new ones using the snap. Any help on what to do is much appreciated!
enter image description here
Update: I fixed it. I think I had improperly configured my firewall, and turning it off (in proxmox)/making some changes to my /etc/netplan/*.yaml file to properly configure the static IP fixed it. GL
Another reason can be a wrongliy configured network. I forgot to set the gateway/proxy for IPv4, so github.com was unreachable. Most other services I use seem to resolve IPv6 first, so I did not have any other problems besides updating nextcloud apps.
When I first uploaded the basic LAMP stack from Bitnami, it was just one .run file. I first was making the mistake of not writing it like this:
./bitnami-lamp-stack.run
Note, full file name was longer, obviously. So, then to install WordPress, there is a native installer. So, I uploaded that, just as instructed. Made it executable. Then ran
./bitnami-wordpress-module.run
Note, again, the actual fine name was different. So, the second command, should find the bitnami installation and add WordPress. Strangely, it just returns immediately without doing anything. I tried it with an without sudo, as I had given read and execute permission temporarily. It just throws me back at the command prompt having done nothing.
I even tried running it from the same directory as where the lamp stack is installed. I am baffled by this and stumped. One idea did come to mind... Maybe I need to add the bitnami lamp stack location to the path. It doesn't seem to require that but who knows.
This is on Ubuntu 14.04.
Thanks in advance for any help,
Bruce
My understanding is that you already have the Bitnami LAMP properly installed and you have troubles installing the module on top of the LAMP. Could you run the module installer with the following option?
./bitnami-wordpress-module.run --mode text
Could you also try to download again the module from the bitnami page and check the md5 of both installers? You can check it with the following command:
md5sum /path/to/installer
I am trying to push Piwigo CMS(http://piwigo.org/) to Cloudcontrol I tried the method as same as Drupal, which is described in https://www.cloudcontrol.com/dev-center/Guides/PHP/Drupal%207 But I am getting this error
This is indeed, as pst pointed out, a pubkey issue.
You might want to check your ssh config, it helped to define the following in my ~/.ssh/config:
Host cloudcontrolled.com
user USERNAME
IdentityFile ~/PATH_TO_YOUR/rsa_key
I dunno if this works as well in cygwin or similar: it would help if you could specify your environment a little bit more, as there are many elements (read binaries, configs, etc) in play here.
I am struggling with Symfony 2 error reporting because I can't find out what really is happing when a 500 Error is triggered.
I have XDebug correctly installed, but it seems like Symfony rules everything.
The custom pages just says:
Oops! An Error Occurred
The server returned a "500 Internal Server Error".
Something is broken. Please e-mail us at [email] and let us know what you were doing when this error occurred. We will fix it as soon as possible. Sorry for any inconvenience caused.
That's pretty much funny! Something is broken, but, the fact is that I need to fix my code, but can't know what or where it is the problem! And sure, If I send an email for the Symfony team will they be able to solve my problem once I not even know what to say them?
Some clue on what I am missing here?
For Symfony 2 and below,
First, look at the logs in app/logs depending on your environment — dev.log for development, prod.log for production, etc.
If the code crashes before Symfony has a chance to run, check the logs of your web server — e.g. nginx.
If you have a symfony flex project, it is also possible that you forgot to install monolog ;) Run:
composer req log
For Symfony versions 3.x, 4.x, 5.x, 6.x and above,
The logs will be found depending on the environment
For dev env - var/logs/dev.log
For prod env- var/logs/prod.log
Also, as the accepted answer suggests, you might have to check the server logs if your app crashes before even reaching Symfony.
Usual location for server logs is listed below -
For apache server - ls /var/log/apache2
For Nginx server - ls /var/log/nginx
sudo chmod -R o+w var/cache/
from inside the project's folder,
solved the problem for me, at least this time :)
There were no errors in Symfony's or web server's logs.
What caused the problem
It turned out that the problem was caused by me previously removing the cache folder, and regenerating the cache, i.e.
rm -fr var/cache/
./bin/console cache:clear
After that, var/cache became drwxr-xr-x.
An even better way to improve your Symfony debugging process is to have Monit monitor your Symfony and Apache logs for any errors and send you emails whenever something bad happens: http://intelligentbee.com/blog/2016/01/12/how-to-monitor-symfony-and-apache-logs-with-mmonit/
In the pursuit of a more professional WordPress dev and deployment environment I am trying to use Capistrano to deploy from my local dev environment to staging and production servers but I can't quite get it to work.
I am on Site5 shared hosting and am deploying to one server with two different domains - staging.example.com and example.com.
I have used https://github.com/markjaquith/WP-Stack as a basis and have added
set :user, "myserveruser" to my config.rb file as the connection didn't work without that.
Running cap deploy:checktells me "You appear to have all necessary dependencies installed" and I can run cap deploy:setup which successfully connects to staging and production creating releases and shared directories etc.
The problem comes when I run cap deploy. Everything seams to work fine until I am prompted for a sudo password. This is not a normal login prompt though and does not allow me to type a password. As I am on a shared host I don't have sudo access anyway.
Its similar to this problem Capistrano is hanging when prompting for SUDO password to an Ubuntu box but the solutions didn't fix all my issues.
I have set default_run_options[:pty] = true which I seam to need but still get the sudo prompt.
I am using passwordless ssh so Capistrano is able to connect and do everything it needs to do without prompting for a password and I am also using an SSH config file to handel agent forwarding so the server can also connect to my git repository. I have confirmed this is working.
I have found other people having similar problems - Capistrano using sudo even with "set :use_sudo, false" - etc but none of the solutions have worked.
I am using default_run_options[:pty] = true and have tried using set :use_sudo, false and default_run_options[:shell] = false but I still have the same issue.
You can view my Terminal output here - http://pastebin.com/5xZmCnyA
I am seriously going crazy! Any help would be greatly appreciated!!!
Cheers
You can't run setup without sudo. That's the only part that REQUIRES sudo, because it makes a directory public_html/staging.exposecreative.org, in your case...
That step shouldn't be required, you can make that directory yourself (assuming you have permission)..
The problem you will face however is that the shared host will expect your index.php to be directly in public_html, for that to work you'd need write permission to whatever directory public_html is in, which your shared host won't allow (almost certainly)
The line default_run_options[:pty] = true has to do with whether Capistrano pretends to be an interactive shell or not. Many commands (sudo included) use this to determine if they should bother asking the user for input, or if they are part of an automated process (
in which case there's no way to ask for input)
My advice (as Capistrano maintainer) - don't try this on a shared host, it almost certainly won't work. (Sorry, their limitations, not ours)
I wrote an extensive post on how to deploy WordPress with Capistrano on a shared host (Bluehost). I use the Roots/Bedrock stack and it only took me about 20 minutes to get up and running.
I made a WordPress development stack using Shipit JS instead of Capistrano because I'm not comfortable with Ruby. Maybe that can help. Feel free to use it and/or post some issues if needed. Regards.
WP-Jungle / Bonzai