If you're not a programmer, this won't make much sense. Don't worry; you can safely ignore it.
The actual source code to this forum is a bit of a mess, thanks to the way the web hosting company set things up. But I just spent a couple of hours reconstructing a clean source tree, using the phpBB 3.1.4 source code, plus the list of currently installed extensions and language packs.
Here's the source code on GitHub.
Only one tiny feature is missing: The version on GitHub lacks the "Active topics" link in the header, which I hacked into the source code in a truly disgusting fashion. I want to recreate it using a proper phpBB 3.1 extension. And my next challenge is to figure out how to upload this clean tree to web host without getting myself banned from the forum again. Think of this as a process of continuous improvement.
Anyway, as you might guess, pull requests are very much welcome! As always, we strongly prefer to use the extension API whenever possible. And if you know how to program, but you don't know anything about git, or GitHub, or Pull Requests, then we'll be happy to help you learn.
If you're looking for a good warm-up task, you could try adding a language pack for a language that you study. Do not let the students of Finnish have all the fun!
For developers: Forum source code on GitHub
- emk
- Black Belt - 1st Dan
- Posts: 1620
- Joined: Sat Jul 18, 2015 12:07 pm
- Location: Vermont, USA
- Languages: English (N), French (B2+)
Badly neglected "just for fun" languages: Middle Egyptian, Spanish. - Language Log: viewtopic.php?f=15&t=723
- x 6323
- Contact:
- aokoye
- Black Belt - 1st Dan
- Posts: 1818
- Joined: Sat Jul 18, 2015 6:14 pm
- Location: Portland, OR
- Languages: English (N), German (~C1), French (Intermediate), Japanese (N4), Swedish (beginner), Dutch (A2)
- Language Log: https://forum.language-learners.org/vie ... 15&t=19262
- x 3309
- Contact:
Re: For developers: Forum source code on GitHub
This is awesome. Thanks Emk!
0 x
Prefered gender pronouns: Masculine
- emk
- Black Belt - 1st Dan
- Posts: 1620
- Joined: Sat Jul 18, 2015 12:07 pm
- Location: Vermont, USA
- Languages: English (N), French (B2+)
Badly neglected "just for fun" languages: Middle Egyptian, Spanish. - Language Log: viewtopic.php?f=15&t=723
- x 6323
- Contact:
Re: For developers: Forum source code on GitHub
aokoye wrote:This is awesome. Thanks Emk!
I have now provided Docker-based setup instructions for running a development version of the site! Assuming you can get Docker running, this makes it much easier to set up a toy forum on your laptop, and to test out your changes.
Here's my local copy:
The next step is writing a script to deploy the latest version to the web host without getting me banned for uploading too many files. Once that's done, we'll have an easy way to test out new extensions before installing them on the main site.
I have to say, modern PHP is much less horrifying than it was back in 2000. They have tools like "composer", which downloads necessary libraries, they have objects, they have model-view-controller libraries, and they have actual plugin APIs. I feared that this was going to be really gross and horrifying, but I'm glad to say that phpBB is not as ugly as I had feared.
If you have any problems getting our version of phpBB to run locally, please go ahead and let us know about them here.
You do not have the required permissions to view the files attached to this post.
1 x
- zenmonkey
- Black Belt - 2nd Dan
- Posts: 2528
- Joined: Sun Jul 26, 2015 7:21 pm
- Location: California, Germany and France
- Languages: Spanish, English, French trilingual - German (B2/C1) on/off study: Persian, Hebrew, Tibetan, Setswana.
Some knowledge of Italian, Portuguese, Ladino, Yiddish ...
Want to tackle Tzotzil, Nahuatl - Language Log: viewtopic.php?f=15&t=859
- x 7030
- Contact:
Re: For developers: Forum source code on GitHub
Fantastic news, thanks!
0 x
I am a leaf on the wind, watch how I soar
- zenmonkey
- Black Belt - 2nd Dan
- Posts: 2528
- Joined: Sun Jul 26, 2015 7:21 pm
- Location: California, Germany and France
- Languages: Spanish, English, French trilingual - German (B2/C1) on/off study: Persian, Hebrew, Tibetan, Setswana.
Some knowledge of Italian, Portuguese, Ladino, Yiddish ...
Want to tackle Tzotzil, Nahuatl - Language Log: viewtopic.php?f=15&t=859
- x 7030
- Contact:
Re: For developers: Forum source code on GitHub
Ok, got the Docker Toolbox dowloaded and
the VM / Kitematic up and running
I've pulled the dell/phpbb image into Kitematic and voila - a phpBB Installer is up and running. Not quite where I want to be...
Inside that VM, I've pulled the forum from Github (which puts it in phpbb/phpBB directory while the image already has a phpBB3 directory ...)
Not sure what is next - should I be using a different container that you've published on DockerHub?
I see that this dell/phpbb image has phpbb version 3.1.3 and not 3.1.4...
so, I'm going to pause and wait for a little guidance.
the VM / Kitematic up and running
I've pulled the dell/phpbb image into Kitematic and voila - a phpBB Installer is up and running. Not quite where I want to be...
Inside that VM, I've pulled the forum from Github (which puts it in phpbb/phpBB directory while the image already has a phpBB3 directory ...)
Not sure what is next - should I be using a different container that you've published on DockerHub?
I see that this dell/phpbb image has phpbb version 3.1.3 and not 3.1.4...
so, I'm going to pause and wait for a little guidance.
0 x
I am a leaf on the wind, watch how I soar
- emk
- Black Belt - 1st Dan
- Posts: 1620
- Joined: Sat Jul 18, 2015 12:07 pm
- Location: Vermont, USA
- Languages: English (N), French (B2+)
Badly neglected "just for fun" languages: Middle Egyptian, Spanish. - Language Log: viewtopic.php?f=15&t=723
- x 6323
- Contact:
Re: For developers: Forum source code on GitHub
zenmonkey wrote:I've pulled the dell/phpbb image into Kitematic and voila - a phpBB Installer is up and running. Not quite where I want to be...
Inside that VM, I've pulled the forum from Github (which puts it in phpbb/phpBB directory while the image already has a phpBB3 directory ...)
Very close, but my docs were unclear, and the solution is actually the other way around. Sorry about that.
Specifically, you need to check out the source code first, and then use "docker-compose" to download and configure the appropriate containers. (The container setup is all configured here, which makes use of this Dockerfile to describe the necessary customizations to the PHP container.)
I've improved the setup instructions, which should now walk you through the process from beginning to end, although if you're running Windows, then you may need to install the 'git' version controls manually and use the Unix-style terminal that ships with 'git' (or make appropriate changes to the setup instructions).
Good luck, and please don't hesitate to let me know if you have more questions! And my apologies for the bad docs.
1 x
- zenmonkey
- Black Belt - 2nd Dan
- Posts: 2528
- Joined: Sun Jul 26, 2015 7:21 pm
- Location: California, Germany and France
- Languages: Spanish, English, French trilingual - German (B2/C1) on/off study: Persian, Hebrew, Tibetan, Setswana.
Some knowledge of Italian, Portuguese, Ladino, Yiddish ...
Want to tackle Tzotzil, Nahuatl - Language Log: viewtopic.php?f=15&t=859
- x 7030
- Contact:
Re: For developers: Forum source code on GitHub
Ok, that is clearer - however I am unable to get the database created. Background - I'm running this off MacOS (Yosemite),
VM box seems fine (Linux 2.6...)
The command:
fails with
Error in Kitematic is:
VM box seems fine (Linux 2.6...)
The command:
Code: Select all
echo 'CREATE DATABASE phpbb;' | docker-compose run --rm setup mysql -h db -u root -proot
fails with
Code: Select all
Cannot start container 2373ce63e723f4b80b822dec5149158cfad1be715b9881f34379498235398693: Cannot link to a non running container: /phpbb_db_1 AS /phpbb_setup_run_1/db
Error in Kitematic is:
Code: Select all
150817 13:59:55 [Note] mysqld (mysqld 5.5.45) starting as process 1 ...
150817 13:59:55 [Warning] Setting lower_case_table_names=2 because file system for /var/lib/mysql/ is case insensitive
150817 13:59:55 [Note] Plugin 'FEDERATED' is disabled.
mysqld: Table 'mysql.plugin' doesn't exist
150817 13:59:55 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
150817 13:59:55 InnoDB: The InnoDB memory heap is disabled
150817 13:59:55 InnoDB: Mutexes and rw_locks use GCC atomic builtins
150817 13:59:55 InnoDB: Compressed tables use zlib 1.2.3
150817 13:59:55 InnoDB: Using Linux native AIO
150817 13:59:55 InnoDB: Initializing buffer pool, size = 128.0M
150817 13:59:55 InnoDB: Completed initialization of buffer pool
150817 13:59:55 InnoDB: Operating system error number 13 in a file operation.
0 x
I am a leaf on the wind, watch how I soar
- emk
- Black Belt - 1st Dan
- Posts: 1620
- Joined: Sat Jul 18, 2015 12:07 pm
- Location: Vermont, USA
- Languages: English (N), French (B2+)
Badly neglected "just for fun" languages: Middle Egyptian, Spanish. - Language Log: viewtopic.php?f=15&t=723
- x 6323
- Contact:
Re: For developers: Forum source code on GitHub
zenmonkey wrote:Code: Select all
150817 13:59:55 InnoDB: Operating system error number 13 in a file operation.
OK, that appears to be a file permissions error involving your "phpBB/db" directory. You could try running:
Code: Select all
cd phpbb
chmod -R a+rwX ./db
This makes your scratch db directory world readable and world writable, which is usually fine on a dev machine. If MacOS doesn't support capital "X" as an argument to chmod, try leaving it off.
Anyway, let me know if this works, and once we get you running, we can fix the install instructions to work on MacOS X.
0 x
- zenmonkey
- Black Belt - 2nd Dan
- Posts: 2528
- Joined: Sun Jul 26, 2015 7:21 pm
- Location: California, Germany and France
- Languages: Spanish, English, French trilingual - German (B2/C1) on/off study: Persian, Hebrew, Tibetan, Setswana.
Some knowledge of Italian, Portuguese, Ladino, Yiddish ...
Want to tackle Tzotzil, Nahuatl - Language Log: viewtopic.php?f=15&t=859
- x 7030
- Contact:
Re: For developers: Forum source code on GitHub
on executing: docker-compose run --rm setup
still getting :
a check,
>ls -l ./db results in:
still getting :
Code: Select all
150817 16:02:15 [Note] mysqld (mysqld 5.5.45) starting as process 1 ...
150817 16:02:15 [Warning] Setting lower_case_table_names=2 because file system for /var/lib/mysql/ is case insensitive
150817 16:02:15 [Note] Plugin 'FEDERATED' is disabled.
mysqld: Table 'mysql.plugin' doesn't exist
150817 16:02:15 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
150817 16:02:15 InnoDB: The InnoDB memory heap is disabled
150817 16:02:15 InnoDB: Mutexes and rw_locks use GCC atomic builtins
150817 16:02:15 InnoDB: Compressed tables use zlib 1.2.3
150817 16:02:15 InnoDB: Using Linux native AIO
150817 16:02:15 InnoDB: Initializing buffer pool, size = 128.0M
150817 16:02:15 InnoDB: Completed initialization of buffer pool
150817 16:02:15 InnoDB: Operating system error number 13 in a file operation.
InnoDB: The error means mysqld does not have the access rights to
InnoDB: the directory.
InnoDB: File name ./ibdata1
InnoDB: File operation call: 'create'.
InnoDB: Cannot continue operation.
a check,
>ls -l ./db results in:
Code: Select all
drwxrwxrwx 16 - staff 544 Aug 17 15:12 driver
-rw-rw-rw- 1 - staff 876 Aug 17 15:12 html_migrator_output_handler.php
-rw-rw-rw- 1 - staff 1909 Aug 17 15:12 log_wrapper_migrator_output_handler.php
drwxrwxrwx 10 - staff 340 Aug 17 15:12 migration
-rw-rw-rw- 1 - staff 21682 Aug 17 15:12 migrator.php
-rw-rw-rw- 1 - staff 808 Aug 17 15:12 migrator_output_handler_interface.php
-rw-rw-rw- 1 - staff 463 Aug 17 15:12 null_migrator_output_handler.php
-rw-rw-rw- 1 - staff 3609 Aug 17 15:12 sql_insert_buffer.php
-rw-rw-rw- 1 - staff 78260 Aug 17 15:12 tools.php
0 x
I am a leaf on the wind, watch how I soar
- emk
- Black Belt - 1st Dan
- Posts: 1620
- Joined: Sat Jul 18, 2015 12:07 pm
- Location: Vermont, USA
- Languages: English (N), French (B2+)
Badly neglected "just for fun" languages: Middle Egyptian, Spanish. - Language Log: viewtopic.php?f=15&t=723
- x 6323
- Contact:
Re: For developers: Forum source code on GitHub
zenmonkey wrote:a check,
>ls -l ./db results in:Code: Select all
drwxrwxrwx 16 - staff 544 Aug 17 15:12 driver
-rw-rw-rw- 1 - staff 876 Aug 17 15:12 html_migrator_output_handler.php
-rw-rw-rw- 1 - staff 1909 Aug 17 15:12 log_wrapper_migrator_output_handler.php
drwxrwxrwx 10 - staff 340 Aug 17 15:12 migration
-rw-rw-rw- 1 - staff 21682 Aug 17 15:12 migrator.php
-rw-rw-rw- 1 - staff 808 Aug 17 15:12 migrator_output_handler_interface.php
-rw-rw-rw- 1 - staff 463 Aug 17 15:12 null_migrator_output_handler.php
-rw-rw-rw- 1 - staff 3609 Aug 17 15:12 sql_insert_buffer.php
-rw-rw-rw- 1 - staff 78260 Aug 17 15:12 tools.php
That looks suspicious. I get:
Code: Select all
> ls -l db/
total 36932
-rw-rw---- 1 999 docker 2 Aug 15 11:10 a039564813af.pid
-rw-rw---- 1 999 docker 27262976 Aug 16 00:21 ibdata1
-rw-rw---- 1 999 docker 5242880 Aug 16 00:21 ib_logfile0
-rw-rw---- 1 999 docker 5242880 Aug 15 10:46 ib_logfile1
drwx------ 2 999 docker 16384 Aug 15 10:46 mysql/
drwx------ 2 999 docker 4096 Aug 15 10:46 performance_schema/
drwx------ 2 999 docker 12288 Aug 15 12:07 phpbb/
Looking at my system, I see:
Code: Select all
# This is your copy of the source tree, checked out from git:
$SOME_DIRECTORY_ON_YOUR_COMPUTER/phpbb
# The database lives here, and permissions need to be correct. You may need to create this.
$SOME_DIRECTORY_ON_YOUR_COMPUTER/phpbb/db
# This is just some random code directory somewhere deep in the tree with source code:
$SOME_DIRECTORY_ON_YOUR_COMPUTER/phpbb/phpBB/phpbb/db/html_migrator_output_handler.php
Also note that 'docker-compose' commands should always be run from "$SOME_DIRECTORY_ON_YOUR_COMPUTER/phpbb", and never from a subdirectory.
My apologies for the unclear instructions; I didn't go into nearly enough detail.
0 x
Return to “Technical Support and Feature Requests”
Who is online
Users browsing this forum: No registered users and 2 guests