wso2-am v210 publish APIS with Hot Deployment - wso2-api-manager

i want to publish APIS to the store by hot deployment/hot update without GUI.
Is there a feature like copy a yaml/xml to a specific Directory or is it possible to do this with the AdminServices?
If yes, how could i configure it?
Thanks for time.

This is not possible at the moment. If you use API import/export you can create the API. But you need to manually publish the API. By doing this you don't need to create the API from the scratch.

Related

how to automatically deploy to firebase on commit to main branch?

The Main part
I am trying to create a comfortable workflow for myself. I just want to know is there any way to automate deploys from GitHub Repo to Firebase hosting when I commit changes in the repo's main branch at my desktop and push origin to GitHub?
...possibly using "GitHub actions"...
Context and what I've tried
As on 15-Jan-2022 there are two ways I found of deploying website files to firebase hosting.
The de facto firebase cli way, where you use firebase deploy command to push files to firebase hosting.
The automated way using github actions, where the site is deployed automatically every time a pull request is created.
The first one is tedious, the second one is not my cup of cake. Especially because the workflow I want to setup is not too much git oriented, I don't use "pull requests" as far as I understand. I just commit changes directly in the main branch.
(That is so because, I am not a programmer, I just trying to create a blogging site using the Firebase hosting + GitHub repo)
I also referred https://medium.com/firebase-developers/the-comprehensive-guide-to-github-actions-and-firebase-hosting-818502d86c31
Use Deploy to live & preview channels via GitHub pull requests. It will work if you use pull requests to review changes or if you push commits directly to the primary branch.
I would recommend that you use pull requests though. It's a great flow to double check your changes and with the Firebase action it will deploy a temporary preview of the the changes so you can validate everything looks correct.

How to delete site via CLI

Is there a way to delete an app via Firebase CLI?
Our CI creates a temporary Firebase app for a feature branch (based on the CI build number), and then runs tests on it. At the end it needs to delete the app. I'm not entirely sure how this is done. firebase disable:hosting just disables hosting and does not delete the app. This is similar to how we would have used Heroku review apps or Heroku forked apps. A similar CI workflow can also be achieved on Google App engine via versions.
Any pointers would be much appreciated.
The correct command is firebase hosting:disable, which make your site offline. You can not remove your project, instead you can overwrite it by creating a new one with firebase init.
More info here https://firebase.google.com/docs/cli/.
There is currently no public API to delete a Firebase backend.
The recommended practice is to use the same database for testing and (if needed) put each run in its own node under the root. So instead of creating/deleting a new database, you're just create/deleting a node in a single database.
Using the command firebase use <alias> --unaliasand then delete the project from the console https://console.firebase.google.com/
Check before the list of commands with the command -h

Is it possible to publish a git repository or a zip file to CloudControl directly by REST API?

I want to publish a maven project to CloudControl by REST API, not by command line tool, is it possible? That means, create a app by REST API, deploy source or binary code by REST API. Just like Heroku, I can build a url directly into app using REST API https://api.heroku.com/apps/myapp/builds. Thanks very much!
We currently don't provide a way to upload images directly. You'd first have to push to the Git remote which will build the image. All other steps like creating an app/deployment, deploying or adding add-ons are available via the REST-API. You can see examples of the API usage in the python library the command line client uses.

How to use 51Degrees via NuGet with Azure?

I'm tryign to use 51Degrees in a .NET project that I deploy to Azure. August 2011, they released v1.2.1.3 marked as "Azure Compatible":
Foundation can now be deployed on to the Windows Azure Cloud service.
See the release note for full details on requirements and how to
setup. Azure related changes include: Instead of a log file, log
entries are written to a log table Instead of a devices file, previous
device requests are written to a device table A new conditional
compilation symbol - 'AZURE'. AZURE enabled builds will not work in
traditional ASP.NET.
Since then there have been a dozen releases and they are up to v2.1.4.9. However, their documentaiton is super light on how to use it with Azure. In fact, there was a bug originally because v1.2.1.3 stated
To make use of the changes you must create a storage account called
‘fiftyonedegrees’. The foundation will then create two tables, one for
previous devices, and another for logs.
This isn't possible because Azure storage accounts need to be unique across all instances so everyone can't create ones named fifityonedegrees.
Their response was:
After rereading the blog it seems I've made an oversight in this
regard, and will update shortly.
The storage account that the Foundation looks for can be changed in
the Foundation source code. Go to Foundation/Properties/Constants.cs
and change the string 'AZURE_STORAGE_NAME' to the name of your storage
account.
However, I'm still at a loss at how to utilize it within my project. Here's my issues:
I'm not clear whether v1.2.1.3 is the only Azure compatible release, or every release after is Azure compatible. Their documentation doesn't say.
When I install 51Degrees via NuGet, my project doesn't get an App_Data folder created which contradicts their documentation. The web.config file even has entries in it that reference the App_Data folder such as <log logFile="~/App_Data/Log.txt" logLevel="Info"/>.
Based on the response to the Azure storage account bug I quoted earlier, they are sayign IN need to edit the file Foundation/Properties/Constants.cs. However, since I'm installing via NuGet and it's a DLL, NuGet is presumably the wrong approach? Do I need to download the source and compile it myself and wire it up to my project manually?
I'm generally new to .NET, NuGet, VS, etc so appreciate the help.
All versions are Azure compatible from 1.2.1.3 onwards. I'm assuming this is the blog post you were talking about. After you've created your azure storage account, you'll have to edit the Constants.cs file in the source code and add in your account name. It's my understanding that this means you'll have to get access to the source code and edit it directly. One you have done this you'll need to recompile for the software to work correctly. I'm not sure if there is a way to perform the same task using NuGet, but I'll look into it. Hope this helps.

Batch-creation of Alfresco users

Is it possible to create Alfresco users in a "batch" way?
I mean, creating lots of users with a script or calling an API or something.
Thank you!
There is a module for the Share admin console in the Share-Extras project which allows the creation of users from a CSV file. It can found here: http://code.google.com/p/share-extras/wiki/CreateBulkUsers
The alfresco shell tools project allows the batch creation of Alfresco users:
https://code.google.com/p/alfresco-shell-tools/wiki/UsersAndGroupsFun#Create_a_new_user
It wraps the REST APIs mentioned in the other replies in an easy to use manner.
I think the easiest way to do that is to use the addPerson webscript.
Just create a small application that calls the webscript (it's a normal HTTP POST request) with the user data you want.
http://wiki.alfresco.com/wiki/Repository_RESTful_API_Reference#Add_Person
If you're using Alfresco Team, or a recent nightly build, then you can simply upload a CSV / Excel file of users and have them created for you. (It's in Swift too)
You'll find the link to do this in the admin console, and the webscript that backs this is http://localhost:8080/alfresco/service/api/people/upload (perform a GET to fetch the spreadsheet template, or a POST to upload the users)

Resources