we have jelastic, and even with VDS, all changes made in date are not applied to my environments.
how can I change date/time in jelastic?
thanks.
The VDS is a standalone system. The other servers in your environment are separate.
If you want to change the timezone for your other servers, you should ask your hosting provider to do it. However, in most cases you can also specify a timezone at application level (e.g. How to set a JVM TimeZone Properly Managing timezones etc.), so system time would only be relevant for log files and cron.
With Jelastic, you can use the add-on "TimeZone Change" from the MarketPlace.
Note : on some docker containers it will not work
See official documentation : https://docs.jelastic.com/timezone-management
Related
I have a general question about good practices and lets say way of work between docker and IDE.
Right now i am learning docker and docker compose, and i must admit that i like the idea of containers! Ive deployed my whole spring boot microservices architecture on containers, and everything is working really well!
The thing is, that in every place of properties when i am declaring localhost address, i was forced to change localhost to custom container names, for example localhost:8888 --> naming-server:8888. It is okay for running in containers, but obviously when i am trying to run this on IDE, it will fail. I like working/optimizing/debugging microservices in IDE, but i dont want rebuilding image and returning whole docker-compose every time i made a tiny small change.
What does it look like in real dev?
Regards!
In my day job there are at least four environments my code can run in: my desktop development environment, a developer-oriented container environment, and pre-production and production container environments. All four of these environments can have different values for things like host names. That means they must be configurable in some way.
If you've hard-coded localhost as a hostname in your application source code, it will not run in any environment other than your development system, and it needs to be changed to a configuration option.
From a pure-Docker point of view, making these configurable via environment variables is easiest (and Spring can set property values from environment variables). Spring also has the notion of a profile, which in principle matches the concept of having different settings for different environments, but injecting a whole profile configuration can be a little more complex at deployment time.
The other practice I've found helpful is to have the environment variable settings default to reasonable things for developers. The pre-production and production deployments are all heavily scripted and so there's a reasonably strong guarantee that they will have all of the correct environment variables set. If $PGHOST defaults to localhost that's right for a non-Docker developer, and all of the container-based setups can set an appropriate value for their environment at deploy time.
Even though our actual deployment system is based on containers (via Kubernetes) I do my day-to-day development in a mostly non-Docker environment. I can run an individual microservice by launching it from a shell prompt, possibly with setting some environment variables, and services have unit tests that can run just on the checked-out source tree, without needing any Docker at all. A second step is to build an image and deploy it into the development environment, and our CI system runs integration tests against the images it builds.
I use Heroku and want to see logs in the JST timezone, not the UTC.
So I changed the TZ variable on Heroku CLI and checked the JST works by running date command on Heroku bash, but Heroku logs seem to be shown in the UTC.
Are there any solutions to fix this?
I assume by changing the TZ environment, you mean setting TZ on the Dyno. This won't affect logs, as your logs could have many sources (Postgres, Redis etc...). Generally, it's always best to keep all of your services running in UTC, as this will keep debugging across systems easier. If you need to convert your logs to JST for analysis, I recommend setting up a logging add-on like papertrail, this will allow you to view logs in your preferred timezone, while keeping the main log stream in UTC.
According to Jelastic documentation it is possible to export the Environment configuration and download it so it can be restored in another provider
However I have tried with 2 Jelastic providers and they both have disabled the option for exporting private data.
So exporting/download/upload/import of environment is not possible.
i.e. I was expecting to have a process similar to CPanel backup/restore tool
In fact, another view for the deployment process gives a possibility to get rid of the model of handling the data or configuration on the platform. Try to think a bit differently and using CI/CD approach. The Jelastic provides a platform where something you created, locate on somewhere you're elaborating(VCS or GIT as an example) and based on or depends on the specific stack, already pre-configured like a layer and can be installed(copied) over Jelastic. Don't need to handle the data somewhere in the cloud because you have it locally(means within any VCS) and doing the changes there. Then just do a 'pull' procedure(manually or automatically) on that deployment(test, production, staging) environment you're expecting.
Moreover, you can expect any environments type like a code and perform it creating before deploying the data.
Please, find the articles being described each case:
Deployment Guide
Jelastic Packaging Standard for CI/CD Automation
In case you would like to handle the databases' backups, check this article:
Scheduling Database Backups
Additional FTP add-on can make the copies more easily for each instance:
FTP/FTPS Support in Jelastic
Composer version: 0.16.3
It seems composer command by default create/update $HOME/.composer folder. Is it possible to change this folder ? For example, specify some environmental variable, then it create something like $HOME/.composer-stage, $HOME/.composer-production. The purpose is to change the target. E.g. staging environment to production environment for .bna file upgrade.
I remember in 0.12.x, we were able to select connection profiles for target selection.
Thanks !
This is not available at present, but there is an Issue already logged on Github and it is being worked on Hyperledger Composer Issue 3121 - In making the card store more generic it is likely that it will allow you to specify a folder name of your choice.
so the question (and answer here) relates to Hyperledger Composer. The .composer directory represents the wallet or credentials store for business network cards relating to a user connecting to business network(s) whether via CLI, Playground, APIs, REST etc etc. The current answer is no - not presently. See https://github.com/hyperledger/composer/issues/3121 as referred above.
I'm trying to do some clustering testing and I am setting up multiple RabbitMQ services on a single Windows machine. I am able to set the environment variables RABBITMQ_NODENAME, RABBITMQ_SERVICENAME, and RABBITMQ_NODE_PORT then run RabbitMQ-Service Install to have a new RabbitMQ service installed under a different name.
My question is regarding the configuration file. Based on what I read on the RabbitMQ site, the configuration file defaults to the %AppData%\RabbitMQ directory.
I'm just having trouble trying to understand how it should be setup so I can have 3 instances of the service running with their own configuration.
Do I run the installation under a different local or domain account so it gets placed under a different %AppData%\RabbitMQ directory or can I add a directive to the service to look in a particular directory for the configuration file for that particular service?
Also, how does RABBITMQ_BASE come into play? Is that only for data and log files or does that also apply to the configuration file? I'm not sure if once I have the service setup with BASE defined as a specific path I can place a new rabbitmq.config under the root of that path.
Please confirm and provide any additional assistance. Thank you in advance!
For now I'm testing on Windows but I plan on converting to linux once I have this all working correctly and understood. Unfortunately, I've inherited the current environment and it's already installed and running using Windows servers. They just wanted me to setup clustering for it so I'm trying to simulate the cluster on my workstation.
Nevermind, I found out what I needed. The environment variable RABBITMQ_CONFIG_FILE can be used to override the location of the default config file.
http://www.rabbitmq.com/relocate.html
You can run multiple RabbitMQ instances on 1 machine without clustering. You just need to change the ports and the node name in rabbitmq-defaults, rabbitmq-env and config files. If you want them as a service you can just create them from the already configured instances.
HERE is a detailed guide on how to do that. It's pretty easy and straightforward.