Comments (4)
@a-nldisr There are a couple of ways you can do this
- You dump the dataset to an external mysql server and provide the database connection details while running the image via DB_HOST, DB_NAME, DB_USER and DB_PASSWORD environment variables.
- Second way is to build the image from the dockerfile. In the resources/redmine file on line 75-76 you will see that the database is created. You will need to add sql commands following that to allow remote access to the mysql server using the GRANT mysql command. Something similar to
GRANT ALL ON *.* TO 'root'@'172.17.%.%' IDENTIFIED BY '' WITH GRANT OPTION;
FLUSH PRIVILEGES;
Save the changes, build and run the image. Following which you should be able to connect to the mysql server like so.
mysql -h container-ip-address -uroot
Personally I would like to have a robust solution to this feature, wherein you can specify a dump file while running the image and the container will import the provided dataset. But I dont think it is possible without mounting volumes and such. Right now I think the second option is more suited to your needs.
from docker-redmine.
@a-nldisr I can do one thing though, I could add a environment variable to configure the mysql server to allow remote connections. It is not done so by default for security reasons
from docker-redmine.
Currently i have a redmine project that has a deadline, to lighten the workload of setting up an development environment i was looking at Docker (and as added bonus: Learn Docker). However adding these steps to building a docker environment for just adding a data set complicates the quick setup i was looking for, the time i spend looking into docker specific actions i could have started a virtual machine. I still believe it would be a nice feature to load in your own data sets into the database with 1-2 commands.
For now im working again with a VM that i created for development purposes, i'll look at the suggested solutions in due time. Thanks for your time!
from docker-redmine.
@a-nldisr FYI, the root user is now assigned a randomly generated password when the image is run. This means that you can now ssh to container and dump the test database to the internal mysql server.
The first line of
docker log <container-id>
gives away the password for the root user. The assigned password is dynamic and changes every time the image is run/started.
from docker-redmine.
Related Issues (20)
- Multiple problems on rebuilding the redmine image HOT 3
- Upgrade from 5.1.0 to 5.1.1-1 rake aborted HOT 9
- postgresql container fails to start and report error: popen failure: unable to allocate memory initdb: error: The program "postgres" is needed by initdb but was not found in the same directory as "/usr/lib/postgresql/14/bin/initdb". HOT 2
- How to upgrade from sameersbn/redmine: 4.1.1-8 to sameersbn/redmine: 5.1.1-1 ? HOT 5
- redmine:5.1.1-1 ocker-compose up error HOT 3
- An error occurred while sending mail HOT 10
- Can't download large files HOT 4
- Build is failing HOT 4
- Run sameersbn/redmine with an External Azure MySQL database HOT 2
- 5.1.1-4 dies because of Matrix in gem HOT 7
- MOving back from 5.1.1 to 5.0.7 HOT 1
- Bug: github workflow should only tag "latest" for changes to master branch HOT 2
- Failed: Upgrade from 5.0.7 -> 5.1.2 on Synology Docker HOT 4
- ERROR 1193 (HY000) at line 1: Unknown system variable 'tx_isolation' with a MySQL DB version 8.1 HOT 5
- Container is not able to connect to the internet using the bridge network on Synology DSM 7.2 HOT 9
- IMAP email job not working in 5.1.2+ HOT 6
- container "redmine-mysql-1" does not start with docker v26.0.2 and works with 26.0.1 ... ? HOT 3
- Invalid form authenticity token error HOT 11
- Internet is not ready when plugin installing and rubygems update is required
- Permission to create databases is required to run against an existing Postgres database HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from docker-redmine.