My nextjs front-end app on AWS has a back-end dependency in package.json linked it in this way:
"api-client": "git+https://username:password#bitbucket.org/username/api_client_dev.git".
When I update my backend repository with changes, locally (npm run dev) everything works, but the app on AWS (with Amplify), when building recognizes an error type about a variable referring to something I haven't done yet.
My front-end doesn't recognize the updated repository.
If I check my repo on bitbucket is updated.
No problems with branches.
I don't understand why. Any suggestion?
Thank you
The problem was in amplify.yml
Adding the script npm update on pre-build, force amplify to refresh cached dependencies on node_modules, my dependency included.
Related
I am currently trying to download a dependency from an Amazon S3 bucket for a maven framework project but Intellij is unable to download when I compile. In the .m2 repository it shows the folder for the dependency, it just doesn't contain the required information. There is also a settings file in the .m2 providing a username and password to the S3. In the Intellij console all dependencies are underlined in red in the maven window but only the two dependencies relying on the S3 are not being imported. Also, when I install the locally they are found and work fine.
Some of the actions I have taken:
Deletion of the repository
Deletion of the .m2 folder
Invalidate and cache
Reloading all projects
Downloading sources and documentation
Rebuilding
Installing locally (as mentioned above)
Reinstalling Intellij
Deleting the project and re-loading from code commit
If anyone has any ideas then I would be very grateful to try them out!
You can locate the proper Maven dependencies in the POM file that is located in the AWS Example Github located here:
https://github.com/awsdocs/aws-doc-sdk-examples/tree/master/javav2/example_code/s3
This POM file is valid within an INtelliJ project:
This only started happening tonight, and even after reverting my totally not-npm related changes it's still happening.
I've got an AWS Elastic Beanstalk setup here where I'm calling eb deploy to deploy a KeystoneJS cms application. As part of the deployment it runs npm install, and I've got a custom fork/branch of the keystone github repo that it's supposed to install. And it does! But for some inexplicable reason /lib/core/ in the Keystone repo is just... not there. I get errors complaining about those missing files, and sure enough the entire folder is not present. They are just not npm installed, despite the rest of the Keystone repo being installed just fine.
I can't reproduce this locally. I'll run npm install, it adds that folder. I'll do npm install <my-fork>, it adds the folder. Every combination locally works just fine, and every deployment I've done to EBS in the PAST has worked just fine. Only tonight has this folder stopped showing up in my installations.
Is it a problem with Elastic Beanstalk? Is it a problem with npm? I've made sure to sync my local npm version (6.8.0) with the EB one, no difference. I've checked to make sure I don't have any .ebignore or .npmignore or .gitignore that might somehow be blocking the core folder, nothing. Unless there's one secretly controlling the temp folder that gets first installed to? I don't know why this would suddenly be an issue though, when it wasn't a couple weeks ago.
Anyone experienced anything like this?
[Edit] For some additional details, changing the keystone version in my package.json to just keystone: "4.0.0" gets me those core files fine. If I install directly from the associated keystone repo, keystone: "keystonejs/keystone", they aren't there. This is again just on the eb install tho, the core files show up for both if I do them locally. But on eb when I install from a git url, which I need to for my specific fork/branch, I see this issue.
Well, I figured it out!
https://npm.community/t/npm-pack-leaving-out-files-6-8-0-only/5382
Someone broke npm 6.8.0. Let my tale be a cautionary one, don't have your deployment scripts set to auto-update npm to the latest version.
I have upgraded nexus repository from 2.x to 3.x through following path:
2.4.14 -> 3.4.0 -> 3.5.1
All nexus services were packed in docker with data directory mapped from host's. For all services I use default either sonatype/nexus or sonatype/nexus3 containers. Nexus web interface is hidden behind nginx with simple reverse proxying.
I use the nexus service with boot-cj (with no credentials) tools which manages dependencies the same way as maven. Anyway the tool first downloads nexus-maven.xml with relevant sha1 files and tries to download jars. It works fine with all 2.x I had.
I created a proxy repository against remote sonatype-snapshots repo. When I start compilation I have Could not find artifact error. I found that the meatdata files are cached but all poms and jars.
I have tried to fix it by cleaning cache with the clean_cache file trick and more rough rm -rfv /srv/nexus3/nexus-data/cache/* with no success. There are no any logs about error. Also I have checked manually that required artefact exists in the remote repository. More obvious Rebuild index button gave no solution. I do not thing it is a problem with nginx, but who knows? Also leaving overnight to run the scheduled tasks did not help.
The expected artifact is org.eclipse.rdf4j:rdf4j:pom:2.3-20170901.145510-11.
I am trying to deploy a webapp to Azure. I am following these directions https://azure.microsoft.com/en-us/documentation/articles/web-sites-python-create-deploy-django-app/
First step, I created a webapp (Django) on the portal.
Then it says to follow the directions to configure Continuous deployment using GIT in Azure App Service. This should apparently lead to my having a local directory of Django files. https://azure.microsoft.com/en-us/documentation/articles/web-sites-publish-source-control/
So I follow those directions, installing Git, creating a local repository, adding a webpage, enabling web app repository, deploying.
The webportal now shows that I have deployed ('active' deployment). However, when I go to the web app url, what's showing is NOT what I deployed, but rather what I guess is the default Django app with its urls (login, logout, contacts).
So then I create an actual Django app in my local directory (instead of the static index.html from the directions). I commit and push it to Azure. It shows as being deployed.
The result is the same as before: the default web app is showing.
So what I'm missing is the connection between my local repository and what's actually showing. Is there some way to pull the Azure default app into my local repository? (Once it's there, I'll be able to change it as I see fit.)
Things are working as expected, but you ended up overwriting the Django app in your first the Git commit. The Continuous Deployment instructions as written are generic to any deployment, even a blank Web App.
So what I'm missing is the connection between my local repository and what's actually showing. Is there some way to pull the Azure default app into my local repository? (Once it's there, I'll be able to change it as I see fit.)
All you need to do is git clone your repo after you've initialized your local Git repo on the Azure Web App. You've already gone through most of these steps, but I'll include them here for others who may be looking for this answer.
After you create the Django Web App from the Azure Marketplace/Gallery, scroll down to set up continuous deployment.
Choose Local Git repo.
Notice that you now have a Git Clone URL in both your Quickstart Essentials info and under All Settings >> Properties. Go ahead and copy this URL.
If you haven't already done so, you may need to set or reset your Deployment Credentials. You'll find this under All Settings. This will be your Git & FTP credentials. Note that this is actually the credentials for your Microsoft Account, not just this one Web App.
You already have Git installed from your first attempt. You should now be able to navigate to the folder you want to clone the repo into and run:
git clone <your_git_clone_url>
After you type in your password, you'll have a cloned repo of the Django Web App on your local system. cd into the directory and start working from there. Once you have changes, git add ., git commit, and git push them back to the repo in Azure to see your changes there.
I have an ember-cli app that is deployed in S3. It works well, and I have Travis set up to deploy changes when there is a merge into the master branch in GitHub.
But sometimes I want to test a change in the deployment environment without a commit -- perhaps because it can only be tested in that environment, like a fix to a mobile-only defect.
So I tried:
ember build --environment=production
followed by:
aws s3 cp dist/ s3://my_bucket/ --recursive
which uploaded things to my bucket. But the page didn't work, my browser told me there was a redirect loop. It wasn't a code issue, because when I pushed the changes to master, Travis successfully deployed them to S3.
Is there something clearly wrong with what I did, copying the dist folder to my bucket?
I'm using Ember-cli 1.3.1, if that matters.
I suggest you use ember-cli-deploy works pretty and support several plugin in order deliver your code much more easier.
I haven been using it for a while a work pretty well.
http://ember-cli.github.io/ember-cli-deploy/plugins/